Java program codes
Friday, 9 September 2011
java even odd program
click on the image to enlarge
class Evenodd
{
public static void main(String args[])
{
int n = Integer.parseInt(args[0]);
if (n%2==0)
System.out.println( " Even Number"+n);
else
System.out.println(" odd Number"+n);
}
}
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment