Computer Science, asked by gsfsdgthgfd, 1 year ago

write a java program to check whether the product of two numbers is a buzz no. or not.

Answers

Answered by webier
6
import java.io.*;
class Buzz
{
public static void main (String ar[]) throws IOException
{
int n,i;
BufferedReader br= new BufferedReader(new InputStreamReader(System.in);
System.out.println("enter a number");
n=Integer.parseInt(br.readLine());
for(i=1;i<=n;i++)
{
if (i%7==0|| i%n==7)
System.out.println(i);
}
}
}
Answered by BrainlyPromoter
3

The program is given in the picture attached with my answer. The program free from any kinds of error.


Buzz number is a type of number which is either divisible by 7 or end with 7.

Attachments:
Similar questions