public void count(String answers, int i) {
        if (countABC[charIntMapping.get(answers.charAt(i))] != 0) {
            result.add(totalCharacters);
            countABC[charIntMapping.get(answers.charAt(i))]--;
            if (countABC[charIntMapping.get(answers.charAt(i))] == 0)
                totalCharacters--;
        }
    }