Anonymous

How To Give Input In Java Program?

1

1 Answers

Alongbar Daimary Profile
Here is giving input in java:

import java.io.DataInputStream;
class TestInput{
public static void main(String[]ar){
DataInputStream this=new DataInputStream(System.in);

int IntegerNumber=0;
try{
IntegerNumber=Integer.valueOf(this.readLine());
}
catch(Exception E){
System.out.println(E );
}
System.out.println("You had Entered:+IntegerNumber);
}
}

Answer Question

Anonymous