using bufferedreader in java to read integer input code example
Example: how to read integer input using bufferedreader java
BufferedReader reader =new BufferedReader(new InputStreamReader(System.in));
int num = Integer.parseInt(reader.readLine());