Hi ALL,
Here I wrote a program for Given Number Divided by 5 or 2 in java.
/**
*
* @author Balamurgan
M
*/
import java.util.Scanner;
public class FindNumber {
public static void
main(String arg[]){
System.out.println("Enter The number :");
Scanner in=new
Scanner(System.in);
int
num=in.nextInt();
if(num%5 ==0)
System.out.println(" Given number is HIFIVE "+num);
if(num%2 ==0)
System.out.println(" Given number id HIEVEN " +num);
}
}
No comments:
Post a Comment