guess the next step: Cocktail shaker sort
Before each step plays, guess what it does. The page then shows the step as the run takes it and says why, the same sentence the watch page says there.
Step 13 of 66
Question 7 of 35
Step 13 of 66
Step 14 of 66
Step 15 of 66
Step 16 of 66
Step 17 of 66
Step 18 of 66
Step 19 of 66
Step 20 of 66
Step 21 of 66
Step 22 of 66
Step 23 of 66
Question 7 of 35
Question 7 of 35
Right.
You guessed: 56 is bigger than 7, so they swap.
What the run did:
56 is bigger than 7, so they are the wrong way round.
Question 7 of 35
Not this time.
You guessed: 56 is not bigger than 7, so they stay.
What the run did:
56 is bigger than 7, so they are the wrong way round.
Question 8 of 35
Question 8 of 35
Right.
You guessed: The biggest number left settles at the right end.
What the run did:
56 is now at the right end of the unsorted part. Nothing bigger is left, so it stays there for good.
Question 8 of 35
Not this time.
You guessed: The smallest number left settles at the left end.
What the run did:
56 is now at the right end of the unsorted part. Nothing bigger is left, so it stays there for good.
Question 8 of 35
Not this time.
You guessed: Everything left is already in order.
What the run did:
56 is now at the right end of the unsorted part. Nothing bigger is left, so it stays there for good.
Question 9 of 35
Question 9 of 35
Right.
You guessed: 12 is bigger than 7, so they swap.
What the run did:
12 is bigger than 7, so they are the wrong way round.
Question 9 of 35
Not this time.
You guessed: 12 is not bigger than 7, so they stay.
What the run did:
12 is bigger than 7, so they are the wrong way round.
Question 10 of 35
Question 10 of 35
Right.
You guessed: 18 is bigger than 7, so they swap.
What the run did:
18 is bigger than 7, so they are the wrong way round.
Question 10 of 35
Not this time.
You guessed: 18 is not bigger than 7, so they stay.
What the run did:
18 is bigger than 7, so they are the wrong way round.
Question 11 of 35
Question 11 of 35
Right.
You guessed: 23 is bigger than 7, so they swap.
What the run did:
23 is bigger than 7, so they are the wrong way round.
Question 11 of 35
Not this time.
You guessed: 23 is not bigger than 7, so they stay.
What the run did:
23 is bigger than 7, so they are the wrong way round.
Question 12 of 35
Question 12 of 35
Right.
You guessed: 31 is bigger than 7, so they swap.
What the run did:
31 is bigger than 7, so they are the wrong way round.
Question 12 of 35
Not this time.
You guessed: 31 is not bigger than 7, so they stay.
What the run did:
31 is bigger than 7, so they are the wrong way round.