Guest User

Untitled

a guest
Jun 20th, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. 1284 -> [0, 100, 200, 100, 200, 300, 600]
  2. 1285 -> [0, 100, 200, 100, 200, 300, 500, 999]
  3. 1286 -> [0, 100, 200, 300, 600]
  4. ...
  5. 13023 -> [0, 100, 170, 100, 200]
  6.  
  7. 0 -> 100
  8. 100 -> 200
  9. 200 -> 100
  10. 100 -> 200
  11. 200 -> 300
  12. 300 -> 100
  13.  
  14. list_1284 = [0, 100, 200, 100, 200, 300, 600]
  15.  
  16. set_1284 = set(list_1284)
  17.  
  18. if len(set_1284) != len(list_1284):
  19. print "There exists a loop"
  20.  
  21. else:
  22. print "No loop exists"
Add Comment
Please, Sign In to add comment