From 3a6befad89ac1228d43edfe59e2f0497e00d49de Mon Sep 17 00:00:00 2001 From: Deven <63876261+devenperez@users.noreply.github.com> Date: Thu, 11 Sep 2025 22:29:47 -0400 Subject: [PATCH] Time: 235 ms (6.82%), Space: 14 MB (2.27%) - LeetHub --- .../3227-vowels-game-in-a-string.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 3227-vowels-game-in-a-string/3227-vowels-game-in-a-string.py diff --git a/3227-vowels-game-in-a-string/3227-vowels-game-in-a-string.py b/3227-vowels-game-in-a-string/3227-vowels-game-in-a-string.py new file mode 100644 index 0000000..f0293bb --- /dev/null +++ b/3227-vowels-game-in-a-string/3227-vowels-game-in-a-string.py @@ -0,0 +1,13 @@ +class Solution(object): + def doesAliceWin(self, s): + """ + :type s: str + :rtype: bool + """ + def isVowel(c): + return len(c) == 1 and c in "aeiou" + + # Count vowels + numVowels = sum(map(isVowel, s)) + + return numVowels > 0 \ No newline at end of file