Practice30Create account

A machine brings, in each step, the smallest not-yet-placed number to the leftmost unarranged position (the rest keep order). Example — Input: 25 17 40 08 → Step I: 08 25 17 40 → Step II: 08 17 25 40. For the input '62 15 48 07 30', how many steps are needed to arrange all numbers in ascending order?

Competition practiceInput-Output
  • A6
  • B4
  • C5
  • D3

Step-by-Step Solution

Steps: 07 62 15 48 30 → 07 15 62 48 30 → 07 15 30 62 48 → 07 15 30 48 62. The order is complete after 4 steps.
Answer: B) 4

Master this topic in 30 minutes a day.

Don't just memorise the answer — build a daily practice habit.

Practice 5 Similar Questions Free →

All Input-Output practice questions

More Input-Output practice

A machine brings, in each step, the largest not-yet-placed number to the leftmost…A word machine brings, in each step, the word earliest in alphabetical order among the…A machine brings, in each step, the smallest not-yet-placed number to the leftmost…An arrangement machine rearranges an input line of numbers step by step by one fixed…An arrangement machine rearranges an input line of numbers step by step by one fixed…