Getting a NZEC error in LEBOMBS problem

I am not able to understand why am i getting NZEC error even though it runs fine in my computer

import java.io.*;

import java.util.*;
class bomb
{
public static void main(String args[])throws IOException
{
//System.out.println(“test”);
BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
Scanner in=new Scanner(System.in);
int test=Integer.parseInt(br.readLine());
while(test–>0)
{ int count=0;
int n=Integer.parseInt(br.readLine());
String s;

      s=br.readLine();
      int a[][]=new int[n][2];
      
      for(int i=0;i<n;i++)
      {
          a[i][0]=a[i][1]=s.charAt(i)-'0';
        }
      
      for(int i=0;i<n;i++)
      {
          if(a[i][0]==1)
          {
              if(i<n-1&&i>0)
              {
                  if(a[i-1][1]!=1)
                  {
                      a[i-1][1]=1;
                      a[i+1][1]=1;
                    }
                    else
                    a[i+1][1]=1;  
                }
              else if(i==0)
              a[i+1][1]=1;
              else
              {if(i==n-1)
              a[i-1][1]=1;}
            }
        }
   
    
    
  
       for(int i=0;i<n;i++)
       {
           if(a[i][1]==1)
           count++;
        }
      System.out.println(n-count);
    }
}

}