Second Most Repeated Word In a Sequence
Given a sequence of strings, the task is to find out the second most repeated (or frequent) string in the given sequence.
Example:
["aaa", "bbb", "ccc", "bbb", "aaa", "aaa"]
should return "bbb"
.
Contributed by Berkan Teber