Advertisement
nanobruh

Untitled

Feb 19th, 2019
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.49 KB | None | 0 0
  1. from itertools import permutations
  2. import time
  3. from collections import Counter
  4.  
  5. time1 = time.time()
  6.  
  7. def main():
  8. CUBES = [a**3 for a in range(1, 10000)]
  9. CUBES_DIGITS = [Counter(str(number)) for number in CUBES]
  10. counter = 0
  11. for a in CUBES_DIGITS:
  12. if CUBES_DIGITS.count(a) > 4:
  13. print(CUBES[counter])
  14. print(a)
  15. counter += 1
  16.  
  17.  
  18.  
  19. if __name__ == '__main__':
  20. print(main())
  21. print(time.time() - time1)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement