- Practice
- About 14 min
- 5 practice questions
Machines that handle words and numbers together
Follow machines that move a word in one step and a number in the next, with words building up from the left and numbers from the right.
If something looks wrong, please tell us.
A very common exam machine mixes words and numbers in the same line. Typically words are arranged in dictionary order from the left end, while numbers are arranged by size from the right end, and the two kinds of moves take turns. The two groups never get in each other's way, so the method is to follow each group on its own while writing the whole line at every step.
A typical rule
- In Step I, the word that comes first in the dictionary moves to the extreme left.
- In Step II, the largest number moves to the extreme right.
- In Step III, the next word in dictionary order moves to the second place from the left.
- In Step IV, the next largest number moves to the second place from the right.
- This goes on, with a word on odd steps and a number on even steps, until the line is complete.
Everything not moved keeps its relative order and slides along. Words end up in dictionary order on the left. Numbers end up in ascending order on the right, because the largest is placed at the far right first.
Write two lists first: the words in dictionary order and the numbers from largest to smallest. Then each step takes the next unused item from the right list.
Worked example 1
Input: jam 48 fig 73 axe 25. The words in order are axe, fig, jam. The numbers from largest are 73, 48, 25.
| Step | Arrangement |
|---|---|
| Input | jam 48 fig 73 axe 25 |
| I | axe jam 48 fig 73 25 |
| II | axe jam 48 fig 25 73 |
| III | axe fig jam 48 25 73 |
| IV | axe fig jam 25 48 73 |
Step I moved axe to the left end. Step II moved 73 to the right end. Step III moved fig to second place. Step IV moved 48 to the second place from the right, completing the line. The machine takes 4 steps.
Worked example 2
Input: 64 hat 27 dew 85 kit 30. The words in order are dew, hat, kit. The numbers from largest are 85, 64, 30, 27.
| Step | Arrangement |
|---|---|
| Input | 64 hat 27 dew 85 kit 30 |
| I | dew 64 hat 27 85 kit 30 |
| II | dew 64 hat 27 kit 30 85 |
| III | dew hat 64 27 kit 30 85 |
| IV | dew hat 27 kit 30 64 85 |
| V | dew hat kit 27 30 64 85 |
The first word dew goes to the left end, then 85 to the right end, then hat to second place, then 64 to the second place from the right, and finally kit to third place from the left. Now the numbers read 27 30 64 85 in ascending order. The machine takes 5 steps.
Common mistakes
- Moving a number to the left end. Numbers fill from the right in this machine.
- Forgetting that the word in Step III goes to the second place, not the first. The first place is already taken.
- Dropping an item while rewriting the line. Count the items after each step.
- Comparing words by length instead of dictionary order.
Questions you may be asked
The usual questions are: what is Step III; which item is at the third place from the left in Step IV; how many numbers are to the right of a particular word in the last step; and in which step a particular item moves. In Example 1, the item 73 is moved in Step II and the word fig in Step III. In Example 2, the word that is third from the left in the last step is kit.
Key takeaways. Words are built up from the left, numbers from the right. Odd steps move a word and even steps move a number, unless the rule says otherwise. Prepare the two ordered lists first, then place one item per step and recount the line each time.
Check your understanding
-
1. Rule: odd steps move the next word in dictionary order to the next free place from the left; even steps move the largest remaining number to the next free place from the right. Input: jam 48 fig 73 axe 25. What is Step III?
- axe jam 48 fig 25 73
- axe fig jam 48 25 73
- axe fig jam 25 48 73
- fig axe jam 48 25 73
Show answer
Answer: B. Step I: axe jam 48 fig 73 25. Step II: axe jam 48 fig 25 73. Step III: fig moves to second place, giving axe fig jam 48 25 73.
-
2. Rule: odd steps move the next word in dictionary order to the next free place from the left; even steps move the largest remaining number to the next free place from the right. Input: jam 48 fig 73 axe 25. In which step is the machine complete?
- Step IV
- Step III
- Step V
- Step VI
Show answer
Answer: A. Step IV moves 48 to the second place from the right, giving axe fig jam 25 48 73, which has words in dictionary order and numbers in ascending order.
-
3. Rule: odd steps move the next word in dictionary order to the next free place from the left; even steps move the largest remaining number to the next free place from the right. Input: 64 hat 27 dew 85 kit 30. What is Step II?
- dew 64 hat 27 85 kit 30
- dew hat 64 27 kit 30 85
- dew 64 hat 27 kit 30 85
- hat dew 64 27 85 kit 30
Show answer
Answer: C. Step I: dew moves to the left end, giving dew 64 hat 27 85 kit 30. Step II: 85 moves to the right end, giving dew 64 hat 27 kit 30 85.
-
4. Rule: odd steps move the next word in dictionary order to the next free place from the left; even steps move the largest remaining number to the next free place from the right. Input: 64 hat 27 dew 85 kit 30. What is the line in the last step?
- dew hat kit 85 64 30 27
- dew hat kit 30 27 64 85
- kit hat dew 27 30 64 85
- dew hat kit 27 30 64 85
Show answer
Answer: D. The words end in dictionary order on the left (dew, hat, kit) and the numbers in ascending order on the right (27, 30, 64, 85).
-
5. In this machine the input has numbers 15, 62, 40 and 71 and the words rat, ink and oak. Which number moves in Step IV?
- 62
- 71
- 40
- 15
Show answer
Answer: A. The numbers move in order from the largest. The largest, 71, moves in Step II, and the second largest, 62, moves in Step IV.
Sign in to keep track of the lessons you finish.