You are viewing a single comment's thread. Return to all comments →
Python
def catAndMouse(x, y, z): a_dist = abs(x-z) b_dist = abs(y-z) if a_dist == b_dist: return 'Mouse C' elif a_dist > b_dist: return 'Cat B' else: return 'Cat A'
Cats and a Mouse
You are viewing a single comment's thread. Return to all comments →
Python