BufferedReader br = new BufferedReader (new InputStreamReader (System.in)); BigInteger num=BigInteger.ONE; System.out.println("Please input the value for num."); num=new BigInteger(br.readLine());