You are viewing a single comment's thread. Return to all comments →
def minion_game(string): n=len(string) gauss_formula = ((n*(n+1))//2) vocals = "AEIOU" kevin = sum(n-i for i,char in enumerate(string) if char in vocals ) stuart = gauss_formula - kevin if kevin == stuart: print( "Draw") elif kevin > stuart: print( "Kevin", kevin) else: print( "Stuart", stuart )
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 →