console java

Solutions on MaxInterview for console java by the best coders in the world

showing results for - "console java"
Silvia
11 Jul 2018
1try(Scanner scan=new Scanner(System.in)){
2	//read from console
3	String textRead=scan.nextLine();
4	//write to console
5  	System.out.println(textRead);
6}
Mellina
04 Jul 2019
1# comile Java class
2javac YourClass.java
3# run compiled Java class
4java YourClass
5# run Java class directly
6java YourClass.java
7# run JAR
8java -jar YourJar.jar