IBPS PO · Reasoning Ability

Machine Input-Output

Step-by-step word/number rearrangement following a hidden rule.

Share with your prep group:WhatsApp

Test yourself on Machine Input-Output

5 real IBPS PO questions with instant answers — no signup, ~3 minutes.

Take the 5-question quiz →

Machine Input-Output

Overview

Machine Input-Output is a reasoning topic where you are given an initial arrangement of words and/or numbers, and shown how a hypothetical "machine" rearranges them step-by-step until reaching a final output. Your job is to decode the hidden rule governing each step, then apply it to answer questions about intermediate or final arrangements.

This topic typically carries 5 questions in IBPS PO Prelims, often appearing as a single set. It tests pattern recognition, systematic thinking, and the ability to track multiple elements through sequential changes. Once you crack the rule, all five questions become quick marks—but missing the pattern can cost you the entire set. Mastering this topic is high-reward because the questions are predictable once the logic is understood.

The key challenge is that the rule is never stated explicitly. You must infer it by comparing the input with each subsequent step, observing which element moves and where it lands.

Key Concepts

  • **The machine follows a consistent rule at every step.** Whatever operation happens in Step 1 repeats in the same logical manner in Step 2, Step 3, and so on.
  • **Elements are typically rearranged, not removed or added.** The same words and numbers from the input appear in the output—only their positions change.
  • **Common operations involve sorting:** arranging words alphabetically (A→Z or Z→A) or numbers in ascending/descending order, one element per step.
  • **Position matters:** Elements may be picked from the left end, right end, or based on a specific property (smallest number, first word alphabetically).
  • **Dual-end movement is common:** One word may move to the left while one number moves to the right in the same step, or vice versa.
  • **The final output is the stopping point:** When no further rearrangement is needed (fully sorted), the machine halts.
  • **Counting steps from input:** Input is Step 0. The first rearrangement is Step 1. Questions often ask about Step 3 or Step 4, so track carefully.

Formulas / Key Facts

1. **Alphabetical order for words:** Compare first letters; if same, compare second letters (e.g., "bat" comes before "box").

2. **Ascending order:** Smallest to largest (12, 25, 38, 47).

3. **Descending order:** Largest to smallest (47, 38, 25, 12).

4. **Left-end placement:** The selected element moves to position 1 (leftmost).

5. **Right-end placement:** The selected element moves to the last position.

6. **Alternating pattern:** Words may go to one end, numbers to the other—or odd-positioned and even-positioned elements may follow different rules.

7. **Step count:** Total steps = Total elements ÷ Elements moved per step (approximately). For 8 elements moving 2 per step, expect 4 steps.

8. **Reverse alphabetical:** Z→A ordering—"zone" comes before "apple."

Worked Examples

### Example 1: Basic Word-Number Sorting

**Input:** sky 42 pen 18 box 65 arm 31

**Step 1:** arm sky 42 pen 18 box 31 65 **Step 2:** arm box sky 42 pen 18 31 65 **Step 3:** arm box pen sky 42 18 31 65 **Step 4:** arm box pen sky 18 31 42 65

**Decode the rule:**

  • Compare Input to Step 1: "arm" (alphabetically first word) moved to left end; "65" (largest number) moved to right end.
  • Step 2 confirms: "box" (next alphabetical word) goes left; "42" was already in position, so "31" shifts.
  • Pattern: Each step moves the next alphabetically first word to the left end and arranges numbers in ascending order from the right.

**Question:** What is the position of "42" in Step 3? **Answer:** In Step 3, the arrangement is: arm box pen sky 42 18 31 65. Position of "42" = 5th from left.

---

### Example 2: Reverse Pattern

**Input:** 24 march 52 june 11 april 39 may

**Step 1:** 24 march 11 june april 39 may 52 **Step 2:** 24 11 june april 39 may 52 march **Step 3:** 11 june april 39 may 52 march 24 **Step 4:** june april 39 may 52 march 24 11

**Decode the rule:**

  • Step 1: "april" moved toward left (but observe position); "52" moved to right.
  • Looking closely: smallest number moves right, and words are being arranged in reverse alphabetical order (Z→A) from the right end.
  • Alternative reading: Each step picks largest number to the right end and arranges months in reverse calendar order.

**Question:** Which element is 4th from the right in Step 2? **Step 2 arrangement:** 24 11 june april 39 may 52 march **Counting from right:** march(1), 52(2), may(3), 39(4) **Answer:** 39

---

### Example 3: Finding a Specific Step

**Input:** row 17 cat 84 job 53 win 29

You're told the final output is: cat job row win 17 29 53 84

**Question:** How many steps does the machine take?

**Solution:**

  • Words are alphabetically arranged (left side): cat, job, row, win
  • Numbers are in ascending order (right side): 17, 29, 53, 84
  • If one word and one number are placed per step, total steps = 4

Common Mistakes

  • **Confusing Input with Step 1:** Students count the input as Step 1. Fix: Input is always Step 0; the first change produces Step 1.
  • **Assuming only one type of sorting:** Students think only numbers are sorted or only words. Fix: Check both ends—often words go one way, numbers go the other.
  • **Misreading alphabetical order:** Comparing "pen" and "pan"—students pick wrong word. Fix: Compare letter by letter: p-a-n comes before p-e-n.
  • **Losing track of positions:** After 3-4 steps, students miscount positions. Fix: Write out each step fully; count from left starting at 1.
  • **Not verifying the rule:** Students assume a rule after one step. Fix: Always confirm the pattern holds for at least two consecutive steps before answering.

Quick Reference

  • Decode the rule by comparing Input → Step 1 → Step 2.
  • Words usually sort alphabetically; numbers sort by value.
  • One element (or one pair) typically moves per step.
  • Input = Step 0. First rearrangement = Step 1.
  • Final output = fully sorted arrangement where no more moves are needed.
  • Always verify your decoded rule against multiple steps before answering.

You read the notes — now try one

A word and number arrangement machine when given an input line of words and numbers rearranges them following a particular rule in each step. The following is an illustration of input and rearrangement: Input: 45 basket 12 orange 78 chair 33 table Step I: 12 45 basket orange 78 chair 33 table Step II: 12 basket 45 orange 78 chair 33 table Step III: 12 basket 33 45 orange 78 chair table Step IV: 12 basket 33 chair 45 orange 78 table Step V: 12 basket 33 chair 45 orange table 78 Step V is the last step of the rearrangement. As per the rules followed in the above steps, find the appropriate step for the following input: Input: 56 apple 89 pencil 23 eraser 41 bottle Which step number is the following output? 23 apple 41 bottle 56 eraser 89 pencil

Tap an option to check your answer.

👥 Study this together

Invite your prep group — read the same notes, then discuss doubts in this topic's shared room.

Invite to study

Need more? Ask Shishya

Shishya is your personal tutor for this topic. Pick a starter or open a free chat.

Open Shishya tutor →

Practice this topic

Take a full mock
  • Q1 · Machine Input-Output · MEDIUM

    A word and number arrangement machine when given an input line of words and numbers rearranges them following a particular rule in each step. The following is an illustration of input and rearrangement: Input: 45 basket 12 orange 78 chair 33 table Step I: 12 45 basket orange 78 chair 33 table Step II: 12 basket 45 orange 78 chair 33 table Step III: 12 basket 33 45 orange 78 chair table Step IV: 12 basket 33 chair 45 orange 78 table Step V: 12 basket 33 chair 45 orange table 78 Step V is the last step of the rearrangement. As per the rules followed in the above steps, find the appropriate step for the following input: Input: 56 apple 89 pencil 23 eraser 41 bottle Which step number is the following output? 23 apple 41 bottle 56 eraser 89 pencil

  • Q2 · Machine Input-Output · EASY

    A word and number arrangement machine when given an input line of words and numbers rearranges them following a particular rule in each step. The following is an illustration of input and rearrangement: Input: 18 blue 52 green 37 red 64 white Step I: blue 18 52 green 37 red 64 white Step II: blue 18 green 52 37 red 64 white Step III: blue 18 green 37 52 red 64 white Step IV: blue 18 green 37 red 52 64 white Step V: blue 18 green 37 red 52 white 64 Step V is the last step of the rearrangement. As per the rules followed in the above steps, find the appropriate step for the following input: Input: 29 cat 71 dog 43 fish 85 bird What will be Step III?

  • Q3 · Machine Input-Output · MEDIUM

    A word and number arrangement machine when given an input line of words and numbers rearranges them following a particular rule in each step. The following is an illustration of input and rearrangement: Input: 34 lamp 67 phone 21 table 58 chair Step I: 67 34 lamp phone 21 table 58 chair Step II: 67 58 34 lamp phone 21 table chair Step III: 67 58 34 21 lamp phone table chair Step IV: 67 58 34 21 phone lamp table chair Step V: 67 58 34 21 phone table lamp chair Step VI: 67 58 34 21 phone table lamp chair Which step is the last step of the above arrangement?

  • Q4 · Machine Input-Output · EASY

    A word and number arrangement machine when given an input line of words and numbers rearranges them following a particular rule in each step. The following is an illustration of input and rearrangement: Input: 42 rain 15 cloud 88 thunder 61 storm Step I: 15 42 rain cloud 88 thunder 61 storm Step II: 15 cloud 42 rain 88 thunder 61 storm Step III: 15 cloud 42 rain 61 88 thunder storm Step IV: 15 cloud 42 rain 61 storm 88 thunder Step V: 15 cloud 42 rain 61 storm 88 thunder Which of the following will be Step II for the input given below? Input: 77 book 38 pen 91 desk 54 paper

  • Q5 · Machine Input-Output · HARD

    A word and number arrangement machine when given an input line of words and numbers rearranges them following a particular rule in each step. The following is an illustration of input and rearrangement: Input: 25 tiger 63 lion 48 bear 81 deer 37 fox Step I: 81 25 tiger 63 lion 48 bear deer 37 fox Step II: 81 63 25 tiger lion 48 bear deer 37 fox Step III: 81 63 48 25 tiger lion bear deer 37 fox Step IV: 81 63 48 37 25 tiger lion bear deer fox Step V: 81 63 48 37 25 tiger lion fox bear deer Step VI: 81 63 48 37 25 tiger lion fox deer bear How many steps will be required to complete the arrangement for the following input? Input: 52 apple 19 mango 74 orange 33 grape 66 banana

Ask Shishya to explain these →

Notes generated on 22 Jun 2026