Receive this “runtime error (NZEC)” when send code to check. When compiling this code on my computer it works. Please, help.
import java.util.Scanner;
class sample2 {
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner sc=new Scanner(System.in);
int k=sc.nextInt();
for(int j=0;j<k;j++){
int a=sc.nextInt()+1;
int sum=0;
for(int i=a;i>0;i++){
int t=a;
while(a>0){
sum=(sum*10)+a%10;
a=a/10;
}
if(sum==t){
System.out.println(sum);
break;
}
else{
sum=0;
a=i+1;
}
}
}
}
}