Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- >>> l = [[0, 1], [0, 2], [1, 2], [1, 3], [0, 1, 2]]
- >>> l2 = [[4, 1], [4, 0], [1, 3], [1, 0], [4, 0, 1]]
- >>> all([any(i in x for i in y) for x, y in zip(l, l2)])
- True
- >>> l3 = [[5, 2], [5, 2], [3, 0], [0, 2], [5, 0, 2]]
- >>> all([any(i in x for i in y) for x, y in zip(l, l3)])
- False
- >>>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement