hello ppl. i am new to
java. i am using JCreato (Version 3.10.009). thing is when i run this program it wont prompt me to enter the integer values.
can anyone of you tell me why.
import java.io.*;
class max_of_two_numbers
{
public static void main(
String args[])
{
int a;
int b;
try
{
System.out.println("Enter an integer: ");
a = Integer.parseInt(args[0]);
System.out.println("Enter an integer: ");
b = Integer.parseInt(args[0]);
if(a > b)
{
System.out.println(a + " is the biggest.");
}
else
{
System.out.println(b + " is the biggest.");
}
}catch(Exception e)
{
System.out.println("Error");
}
}
}