Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- list2=[[((2, 2), (5, 5)), (4.0, 4.0)], [((4, 2), (4, 8)), (4.0, 4.0)], [((5, 6), (3, 8)), (4.0, 7.0)], [((4, 2), (4, 8)), (4.0, 7.0)], [((5, 6), (3, 8)), (4.0, 7.0)], [((1, 4), (5, 8)), (4.0, 7.0)], [((4, 2), (4, 8)), (4.0, 7.0)], [((1, 4), (5, 8)), (4.0, 7.0)]]
- [((4, 2), (4, 8)), (4.0, 7.0)] ,[((4, 2), (4, 8)), (4.0, 4.0)]
- list3=list2
- i=range(0,len(list2))
- j=range(0,len(list2))
- for i in list2:
- for j in list3:
- if list2[i][0]==list3[j][0] and list2[i][1]!=list3[j][1]:
- list2[i].append(list3[j][1])
- list2.pop(j)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement