For this Question: Given a string s, find the first non-repeating character in the string and return its index. If it does not exist, return -1.First line of the input contains the string s.

<b>Constraints</b>
1<= s. length <= 100000Print the index of the first non- repeating character in a stringInput 
s = "newtonschool"

Output
1

Explanation 
"e" is the first non- repeating character in a string, I have written this Solution Code: import java.io.*;
import java.util.*;



class Main {
    public static void main (String[] args) throws IOException {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        String s = br.readLine();
        System.out.print(nonRepeatChar(s));
    }
    static int nonRepeatChar(String s){
        char count[] = new char[256];
        for(int i=0; i< s.length(); i++){
            count[s.charAt(i)]++;
        }
        for (int i=0; i<s.length(); i++) {
            if (count[s.charAt(i)]==1){
                return i;
            }
        }
        return -1;
    }
}, In this Programming Language: Java, Now tell me if this Code is compilable or not?