Serious Problem
InterviewTime limit1sMemory limit256 MB
Count how many times 2 and e appear in a string of those two characters and report which is more frequent, or yee if tied.
- Level
Easy1 of 10
- Topics
- String, Implementation
- Solved
- No attempts yet
Problem
The pronunciations of 2 and e are similar, so mixing the two when speaking can annoy the listener.
Jimin is using this to drive Eunsu crazy. Given the string s that Jimin said to Eunsu, help determine whether 2 appears more often or e appears more often.
Input
The first line gives the length of the string s.
The second line gives the string s. The length of s is between 1 and 105 inclusive, and s consists only of 2 and e.
Output
If 2 appears more often, output 2; if e appears more often, output e. If the counts are equal, output "yee" (excluding the quotation marks).