You are viewing a single comment's thread. Return to all comments →
PHP brute force:
while (((pow(10,$k)-1)/9) % $n !== 0) { $k++; }
Divide all the repunits until one works.
Seems like cookies are disabled on this browser, please enable them to open this website
Project Euler #129: Repunit divisibility
You are viewing a single comment's thread. Return to all comments →
PHP brute force:
Divide all the repunits until one works.