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.
vowel="AEIOU"
st=0
ke=0
for i in range(len(s)):
if s[i] not in vowel:
st = st + (len(s)-i)
else:
ke = ke + (len(s)-i)
if st>ke:
print("Stuart",st)
elif ke>st:
print("Kevin",ke)
else:
print("Draw")
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
The Minion Game
You are viewing a single comment's thread. Return to all comments →
vowel="AEIOU" st=0 ke=0 for i in range(len(s)): if s[i] not in vowel: st = st + (len(s)-i) else: ke = ke + (len(s)-i) if st>ke: print("Stuart",st) elif ke>st: print("Kevin",ke) else: print("Draw")