You are viewing a single comment's thread. Return to all comments →
def misereNim(s):
xor = reduce((lambda x, y: x ^ y), s) if max(s) == 1: return "First" if xor == 0 else "Second" else: return "Second" if xor == 0 else "First"
Seems like cookies are disabled on this browser, please enable them to open this website
Misère Nim
You are viewing a single comment's thread. Return to all comments →
def misereNim(s):