Ptice
Adrian, Bruno and Goran wanted to join the bird lovers' club. However, they did not know that all applicants must pass an entrance exam. The exam consists of N questions, each with three possible answers: A, B and []. Unfortunately, they couldn't tell a bird from a whale so they are trying to guess the correct answers. Each of the three boys has a theory of what set of answers will work best: Adrian claims that the best sequence is: A, B, C, A, B, C, A, B, C, A, B, C ... Bruno is convinced that this is better: B, A, B, C, B, A, B, C, B, A, B, C ... Goran laughs at them and will use this sequence: C, C, A, A, B, B, C, C, A, A, B, B ... Write a program that, given the correct answers to the exam, determines who of the three was right – whose sequence contains the most correct answers.
[c]5
BAACC
Output
3
BrunoSubmit solution
Coming laterThe grading service will be connected in a later migration step. You can inspect the task and your previous results now.