I just thought a number like 142857 had very good property for the problem, so I searched on Wikipedia. There, I found a link to Cyclic numbers—everything you need is on that page.
I can't imagine how to solve the problem without the Internet.
I just thought a number like 142857 had very good property for the problem, so I searched on Wikipedia. There, I found a link to Cyclic numbers—everything you need is on that page.
I can't imagine how to solve the problem without the Internet.