🦘 Math Kangaroo Grade All Felix 1-2 Ecolier 3-4 Benjamin 5-6 Kadett 7-8 Junior 9-10 Student 11-12 ⇄ switch contest
2013 Math Kangaroo

Problem 28

Problem 28 · 2013 Math Kangaroo Stretch
Logic & Word Problems Counting & Probability work-backwardcasework

Dad made 6 pancakes one after another and numbered them 1 to 6 in the order he made them. Sometimes while he worked his children ran into the kitchen and ate the hottest pancakes. In which of the following orders could the pancakes not have been eaten?

Show answer
Answer: D — 456231
Show hints
Hint 1 of 2
Children always grab the hottest available pancake — the most recently made uneaten one.
Still stuck? Show hint 2 →
Hint 2 of 2
That makes the eating order a stack (last in, first out); test each option for a stack violation.
Show solution
Approach: valid stack pop order
  1. The hottest pancake is the most recently made one not yet eaten, so eating works like popping a stack.
  2. An eating order is possible only if it is a valid stack-pop sequence of 1,2,3,4,5,6.
  3. Order 456231 fails: eating 4, 5, 6 first means 1, 2, 3 are still stacked with 3 on top, so the next pancake eaten must be 3, not 2.
  4. So 456231 could not have happened.
Mark: · log in to save