Runtime error NZEC in the following code

i have try the code in codechef compiler it is giving the following error please help me to solve this.

Runtime error:
NZEC

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 Ccfindpair.main(Main.java:13)

here is the code that I have tried to run :
import java.util.;
import java.lang.
;
import java.io.*;
class Main{
public static void main (String[] args) throws java.lang.Exception
{
Scanner s = new Scanner(System.in);
int t = s.nextInt();
while(t>0){
int count=0;
int n = s.nextInt();
int k = s.nextInt();
int[] a = new int[n];
for(int c=0;c<n;c++) {
a[c]=s.nextInt();
}
for(int p=0;p<n;p++) {
int x = a[p];
for (int q=0;q<n;q++) {
int y = a[q];
if((x+y)==k){
count = count+1;
}
}
}
System.out.println(count);
t–;
}
}
}