You are viewing a single comment's thread. Return to all comments →
def organizingContainers(container): n = len(container) size_of_types = [0] * n size_of_containers = [0] * n for i in range(n): size_of_current_container = 0 for j in range(n): size_of_types[j] += container[i][j] size_of_current_container += container[i][j] size_of_containers[i] += size_of_current_container return "Possible" if sorted(size_of_types) == sorted(size_of_containers) else "Impossible"
Seems like cookies are disabled on this browser, please enable them to open this website
Organizing Containers of Balls
You are viewing a single comment's thread. Return to all comments →