import java.io.*;
import java.util.Scanner;
class EnormousInputTest {
public static void main(String[] args) throws IOException {
Scanner sc= new Scanner(System.in);
int Number=sc.nextInt();
int Divisor=sc.nextInt();
int c=0,i;
int num;
for (i = 0; i <Number ; i++) {
num=sc.nextInt();
if (num%Divisor==0)
c++;
}
System.out.println(c);
}
}
Error-
Exception in thread “main” java.util.NoSuchElementException
at java.util.Scanner.throwFor(Scanner.java:862)
at java.util.Scanner.next(Scanner.java:1485)
at java.util.Scanner.nextInt(Scanner.java:2117)
at java.util.Scanner.nextInt(Scanner.java:2076)
at EnormousInputTest.main(Main.java:8)