Concern a variant of the Josephus Problem in which every second person is eliminated. We assume that n people are arranged in a circle and numbered 1,2.....n clockwise. Then, proceeding clockwise, 2 is eliminated, 4 is eliminated, and so on, until there is one survivor, denoted J(n).
Use the result of the Exercise 1 to compute J( 1000).
Exercise 1
Given a value of n ≥ 2. let 2i be the greatest power of 2 with 2i ≤n. (Examples: If n = 10, i = 3. If n = 16, i = 4.) Let j = n – 2i. (After subtracting 2i. the greatest power of 2 less than or equal to n. from n. j is what is left over.) By using the result of Exercise 2 or otherwise, prove that
J(n)= 2j + 1.
Exercise 2
Use induction to show that J(2i) = 1 for all i > 1.
We need at least 10 more requests to produce the solution.
0 / 10 have requested this problem solution
The more requests, the faster the answer.