Question LR-IO-0072
HardA number-arrangement machine rearranges a line of numbers step by step. In each step it takes the smallest number not yet arranged and moves it to the left end of the unarranged part (just after the numbers already arranged).
Input: 73 12 58 39 86 24 65
How many steps does the machine need to complete the arrangement?
- A.
4
- B.
6
- C.
Sign up free to see the answer and a step-by-step explanation.