Input (read) statement
To read data into variables :
Create an input stream object of the class Scanner.
Associate it with the standard input device. The following statement accomplishes this:
static Scanner console=new Scanner(System.in);
System.in. = Standard input stream object and is designed to input data from standard input device .
Console is the created input stream object .