how to handle large integer input in scanner java code example Example: long input in JAVA Scanner scr=new Scanner(System.in); long l=scr.nextInt();