Guest User

Untitled

a guest
Jul 22nd, 2018
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.29 KB | None | 0 0
  1. def rakamlarina_ayir(sayi):
  2. return [int(i) for i in str(sayi)]
  3.  
  4. def islem(sayi,üs=5):
  5. toplam=0
  6. for i in rakamlarina_ayir(sayi):
  7. toplam+=i**üs
  8. return toplam
  9.  
  10. sonuclar=[]
  11. for i in range(2,1000000):
  12. if islem(i)==i:
  13. sonuclar.append(i)
  14.  
  15. print(sum(sonuclar))
Add Comment
Please, Sign In to add comment