The shuffle

We shuffle a deck of 8 cards as follow:
- Split the deck in 2 equal parts
- Insert cards from the 2nd hand between each card of the 1st hand.

Step 1)
Before Split    After
  1     1         1
  2       5       5
  3     2         2
  4       6       6
  5     3         3
  6       7       7
  7     4         4
  8       8       8

Step 2)
Before Split    After
  1     1         1
  5       3       3
  2     5         5
  6       7       7
  3     2         2
  7       4       4
  4     6         6
  8       8       8


Step 3)
Before Split    After
  1     1         1
  3       2       2
  5     3         3
  7       4       4
  2     5         5
  4       6       6
  6     7         7
  8       9       8

We can see that after iterating the process 3 times, the deck is returned to its original order.

How many shuffles does it require to return a 222222222 cards deck to its original order?

Answer: the number
[My timing : < 100 ms]

All Submission
Problem Maintainer :  Philippe_57721
You need to be logged in to submit answer

Comments / Explanation

Show Comments