@@ -0,0 +1,561 @@
+//Way to read and check inputs like check and read integer inputs only%0A%0Aimport java.util.Scanner;%0A   %0A   public class ScannerDemo%7B%0A           public static void main(String%5B%5D args)%7B%0A   %0A                   Scanner sr = new Scanner(System.in);%0A                   double sum = 0 ;%0A                   int count = 0;%0A                  while(sr.hasNextInt())%7B%0A                          int num = sr.nextInt();%0A                          sum += num;%0A                          count++;%0A                  %7D%0A                  System.out.println(sum/count);%0A         %7D%0A  %7D%0A

Create ScannerDemo.java