Advertisement
Guest User

Untitled

a guest
Aug 30th, 2015
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. import time
  2. import math
  3.  
  4. def primes_sum(limit):
  5. num_list = range(2, limit)
  6. i, counter = 2, 1
  7. while i <= math.sqrt(limit):
  8. num_list = num_list[:counter] + filter(lambda x: x%i!=0, num_list[counter:])
  9. i = num_list[counter]
  10. counter +=1
  11. print sum(num_list)
  12.  
  13. def main():
  14. start_time = time.time()
  15. print range(2000000)
  16. print 'Rum time: '+str(time.time()-start_time)
  17.  
  18. if __name__ == "__main__":
  19. main()
  20.  
  21. Internal error: TypeError: FUNCTION_TABLE[HEAP[(HEAP[(c + 4)] + 28)]] is not a function
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement