- 3
Input and output
How to cout and cin in Java?
5 Respostas
+ 2
There is no cin and cout in Java. You can use Scanner class to get inputs and to print you can use System.out.print() or System.out.println().
- 1
cout and cin are C++ I/O formatting.
for Java, cout is System.out.print("Hello");
and cin is
Scanner in = new Scanner();
int a = in.nextInt();