You are viewing a single comment's thread. Return to all comments →
This is pretty much the same solution I came up with:
def fairRations(B): counting = False count = 0 for b in B: if counting: count += 2 if b % 2: counting = not counting else: if counting: return "NO" return count
Seems like cookies are disabled on this browser, please enable them to open this website
Fair Rations
You are viewing a single comment's thread. Return to all comments →
This is pretty much the same solution I came up with: