write a program in java to input a number and check the number is BUZZ NUMBER or not. [if a number ends with 7 or divisible by 7 then it is said to be BUZZ NUMBER ]
Answers
Answered by
1
Answer:
program in buzz number
Attachments:
![](https://hi-static.z-dn.net/files/d32/9853a237844732e1c17b140e4f94c1f6.jpg)
Answered by
89
import java. util. *
class Buzz
{
public static void main (string args[])
{
Scanner sc= new Scanner (System. in);
int x;
System.out.println ("Enter a number");
x=sc. nextInt ();
if(x%==0||x/10==7)
System.out.println (x+"is Buzz number");
else
System.out.println (x+"is not Buzz");
}
}
Similar questions