Suppose I have a list:
l = [0, 1, 2, 3]
How can I iterate over the list, taking each item along with its complement from the list? That is,
for item, others in ...
print(item, others)
would print
0 [1, 2, 3]
1 [0, 2, 3]
2 [0, 1, 3]
3 [0, 1, 2]
Ideally I'm looking for a concise expression that I can use in a comprehension.