I think the output should be true only when x,y is relatively prime to each other. Can someone please help me understand why the test case (x, y, z) = (4,6,8) should return True instead of False?
okay, thanks. I actually misunderstood the question where I thought only one of the jug should and not two containers combined contain z liters of water after the operation.
Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.