How many 8’s are there in the following sequence which are preceded by 5 but…
2011
How many 8’s are there in the following sequence which are preceded by 5 but not immediately followed by 3 ? 5 8 3 7 5 8 6 3 8 5 4 5 8 4 7 6 5 5 8 3 5 8 7 5 8 2 8 5
Answer: A. 4 — ConceptFor a local sequence condition, inspect every occurrence of the target digit together with its immediate left and right neighbours. Count an occurrence…
- A.
4
- B.
5
- C.
7
- D.
3
Show answer & explanation
Correct answer: A
Concept
For a local sequence condition, inspect every occurrence of the target digit together with its immediate left and right neighbours.
Count an occurrence only when all stated neighbour conditions hold at the same time.
Application
List the occurrences of 8 that are immediately preceded by 5. Their three-digit neighbourhoods are 5-8-3, 5-8-6, 5-8-4, 5-8-3, 5-8-7, and 5-8-2.
Apply the right-neighbour condition. The two 5-8-3 neighbourhoods are excluded because 3 immediately follows 8.
The remaining neighbourhoods are 5-8-6, 5-8-4, 5-8-7, and 5-8-2, giving a count of 4.
Cross-check
Scanning the full sequence again from left to right identifies exactly those same four qualifying occurrences and no others.
Result
Therefore, the required number of 8s is 4.