private static String removeSpaces(String input) {
        char[] withSpace = input.toCharArray();
        input = "";
        for(char element : withSpace) {
            if(element != ' ') {
                input += element;
            }
        }
        return input;
    }