A word arrangement machine, when given an input line of words, rearranges them step by step following a particular rule. An illustration of an input and its rearrangement is given below.
Input: jug saucepan tray kettle spoon
Step I: saucepan jug tray kettle spoon
Step II: saucepan kettle jug tray spoon
Step III: saucepan kettle spoon jug tray
Step IV: saucepan kettle spoon tray jug
Step IV is the last step of this input.
Input: ox lion zebra cheetah monkey crocodile
Following the same rule, how many steps will be needed to complete the arrangement of this input?
Answer & explanation
Correct answer: option 3
The correct answer is Option (3) → Five
Compare each step of the illustration with the one before it. In each step, the longest of the words not yet arranged moves to the next place from the left end, and all the other words keep their order.
Step I: ‘saucepan’ (8 letters) is the longest of the words left, so it moves to the first place from the left
Step II: ‘kettle’ (6 letters) is the longest of the words left, so it moves to the second place from the left
Step III: ‘spoon’ (5 letters) is the longest of the words left, so it moves to the third place from the left
Step IV: ‘tray’ (4 letters) is the longest of the words left, so it moves to the fourth place from the left
After Step IV the words stand from the longest to the shortest, so the arrangement is complete.
Apply the same rule to the input ox lion zebra cheetah monkey crocodile.
Step I: ‘crocodile’ (9 letters) is the longest of the words left, so it moves to the first place from the left, giving crocodile ox lion zebra cheetah monkey
Step II: ‘cheetah’ (7 letters) is the longest of the words left, so it moves to the second place from the left, giving crocodile cheetah ox lion zebra monkey
Step III: ‘monkey’ (6 letters) is the longest of the words left, so it moves to the third place from the left, giving crocodile cheetah monkey ox lion zebra
Step IV: ‘zebra’ (5 letters) is the longest of the words left, so it moves to the fourth place from the left, giving crocodile cheetah monkey zebra ox lion
Step V: ‘lion’ (4 letters) is the longest of the words left, so it moves to the fifth place from the left, giving crocodile cheetah monkey zebra lion ox
After Step V all the words are in their final places, so Step V is the last step: five steps are needed.