I'm working on a Login system in Java and am currently focusing on eMail verification. I'm trying to verify that emails only contain one "@".
To do this I've made a function to return the number of chars in a string:
    public static int numberOfCharsInString(String inputString, Character inputChar) {
        char[] stringToCharArray = inputString.toCharArray();
        int number = 0;
        for (int i = 0; i == inputString.length(); i++) {
            if (stringToCharArray[i] == (inputChar)) {
                number++;
            }
        }
        return number;
    }
There are no compilation errors and the function only returns zero. Any help would be much appreciated.
 
    