Two players, Alice and Bob, are playing a game using a string s consisting of lowercase English letters.
• Alice goes first, followed by Bob, and they alternate turns.
• On Alice’s turn, she must remove any non-empty substring that contains an odd number of vowels.
• On Bob’s turn, he must remove any non-empty substring that contains an even number of vowels.
• The game continues until one player cannot make a valid move — that player loses the game.
• Both players play optimally.
Return true if Alice wins, or false if Bob wins.
The vowels are: a, e, i, o, u.
Input: s = "bcdfg"
Output: false
Input: s = "education"
Output: true
Accepted:
Submission: