You are viewing a single comment's thread. Return to all comments →
what should be the value of n.. please find my login below and let me know what improvemnet can I make:
sum=0 for i in range(1,l+1): if checkPrime(i): //for checking prime number total=0 for j in range(1,6): digits=10**j repunit = (int('1'*digits))
if repunit%i==0: total=total+1 if total==0: sum=sum+i
print(sum)
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #133: Repunit nonfactors
You are viewing a single comment's thread. Return to all comments →
what should be the value of n.. please find my login below and let me know what improvemnet can I make:
sum=0 for i in range(1,l+1): if checkPrime(i): //for checking prime number total=0 for j in range(1,6): digits=10**j repunit = (int('1'*digits))
print(sum)