Talk:Josephus problem: Difference between revisions

Content added Content deleted
(→‎Categorisation of solutions: add explanation for Factor solution)
Line 116: Line 116:
: <code>{ 1 3 4 5 ... 41 }</code>
: <code>{ 1 3 4 5 ... 41 }</code>


: Now we have 1 and 3. Add 3 to 1, which is 4. Take 4 modulo 1 which is 1.
: Now we have 1 and 3. Add 3 to 1, which is 4. Take 4 modulo 3 which is 1.
: <code>{ 1 4 5 6 ... 41 }</code>
: <code>{ 1 4 5 6 ... 41 }</code>