A Mealy system produces a '1' output if the input has been '0' for at least two consecutive clocks followed immediately by two or more consecutive '1's. The minimum number of states for this system is
- (A)
2
- (B)
3
- (C)
4
- (D)
5
A Mealy system produces a '1' output if the input has been '0' for at least two consecutive clocks followed immediately by two or more consecutive '1's. The minimum number of states for this system is
2
3
4
5
ANSWER
The minimum number of states is 4, option (C).
Official answer: CSource: ISRO's final answer key of 15 May 2026
The output is on a '1' input that is at least the second '1' of a run of 1s, where that run came directly after two or more 0s. So the machine must remember how many 0s it has just seen (none, one, or two or more) and whether it is already inside a qualifying run of 1s.
Define states: = no useful 0s seen (start, or after a 1 that did not follow two 0s); = exactly one 0 seen; = two or more 0s seen; = at least one 1 seen right after (inside a qualifying run).
Transitions, written as next state / output for input 0 and input 1: : , . : , . : , . : , .
The first 1 after the zeros gives output 0 (only one 1 so far). Every later 1 in the run gives output 1. The state after exactly one such 1 and the state after two or more such 1s behave identically (on 1 they give output 1 and stay in the run; on 0 they give output 0 and go to ), so they merge into the single state . No more than these four states are needed.
No two of the four states can be merged. is the only state that outputs 1 on input 1, so it differs from every other state. and are told apart by the input sequence : from the outputs are , from they are . and are told apart by : from the outputs are , from they are . and are told apart by : from the outputs are , from they are .
All four states are pairwise distinguishable, so the minimum number of states is .
KEY IDEA
A Mealy detector must remember the count of recent 0s (none, one, two or more) and whether it is inside a qualifying run of 1s. Merge states with identical future behaviour, then check that the rest are pairwise distinguishable by some input sequence.
WATCH OUT FOR
Using a separate state for the first 1 and for later 1s of the run (giving 5 states). Because a Mealy output depends on the input as well as the state, both behave identically and merge. Another slip is forgetting that the 0-count must reach two, which needs its own state.
From the ISRO EC 2025 paper. Every question of this paper · The full paper (PDF, ISRO) · All 6 ISRO Sequential questions, with notes