We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Python
- Strings
- The Minion Game
- Discussions
The Minion Game
The Minion Game
Sort by
recency
|
1312 Discussions
|
Please Login in order to post a comment
Can I understand more why it is sufficient to check the occurences of each character to keep the score, and we do not need the generate the words to check for occurrences?
def minion_game(string): vowels = ('A', 'E', 'I', 'O', 'U') kevin_score = 0 stuart_score = 0 len_str = len(string)
if name == 'main': s = input() minion_game(s)
def minion_game(string): n = len(string) S = string.upper() # be robust to case vowels = set("AEIOU")
who's code passed test case 4?