2021 FRQ 1A

public int scoreGuess (String guess){
    int count = 0;

    for (int i = 0; i <= secret.length() - guess.length(); i++) {
        if (secret.substring(i, i + guess.length()). equals(guess)) {
            count++;
        }
    }

    return count * Math.pow(guess.length(), 2);
}

2021 FRQ 3A

public void addMembers (String[] names, int gradYear) {
    for (string n : names) {
        MemberInfo newM = new MemberInfo (n, gradYear, true);
        memberList.add(newM);
    }
}