Josephus Flavius was a famous Jewish historian of the first century at the time of the Second Temple destruction. During the Jewish-Roman war he got trapped in a cave with a group of 40 soldiers surrounded by romans. The legend has it that preferring suicide to capture, the Jews decided to form a circle and, proceeding around it, to kill every third remaining person until no one was left. Josephus, not keen to die, quickly found the safe spot in the circle and thus stayed alive. How did he did all that?
This problem or its variants are studied for a long time and i have found some formulations from the great book “Concrete Mathematics”, so like to share it with u people.
Lets look that how people get executed if n increases.
Have a look, Voila………. got the pattern. Its a sequence of odd numbers and starts from the start at every power of 2!
Just waiting to formalize it into a mathematical equation.