Counters and Shift Registers: GATE ECE practice questions with solutions
This topic covers ripple and synchronous counters, mod-N design, ring and Johnson counters, shift registers and LFSRs. The 15 original questions follow the GATE EC format: 9 MCQ, 2 MSQ and 4 NAT, from 5 easy, 7 medium and 3 hard.
Three ideas to know:
- Use the smallest n with 2ⁿ at least the required modulus.
- With an asynchronous clear, the decoded state is only a glitch, not a counted state.
- An LFSR reaches the maximum length 2ⁿ − 1 only for particular tap choices.
It helps GATE EC and ECE students revising Digital Circuits for the exam or a semester test. Helpful background: Ripple counters and Johnson counter. Start with the 5 easy questions, then work up to the 3 hard ones.
Related
- Formula sheet: Counters on the GATE EC Digital Circuits Formula Sheet
- How Many Flip-Flops Does a Mod-N Counter Need?
- FPGA Project: A Seven-Segment Seconds Counter
- What Is the Difference Between Blocking and Nonblocking Assignments in Verilog?
- GATE EC Digital Circuits Previous Year Questions with Solutions
Q.1
EasyMCQ1 mark
The minimum number of flip-flops needed to build a mod-50 counter is
Show answer and solutionHide answer and solution
Answer: (B)
Key idea: Use the smallest n with 2ⁿ at least the required modulus.
1. n flip-flops give 2ⁿ states. 2. 2⁵ = 32 < 50 and 2⁶ = 64 ≥ 50.
3. So 6 flip-flops are needed.
Common mistake: Rounding log₂ 50 ≈ 5.64 down gives 5, option (A), which allows only 32 states.
You need: Counters, binary states
Q.2
EasyMCQ1 mark
A 4-bit ring counter, loaded with a single 1 (1000), cycles through how many distinct states?
Show answer and solutionHide answer and solution
Answer: (D)
Key idea: A ring counter with n flip-flops has n states; a Johnson counter has 2n.
1. The single 1 moves one place per clock: 1000, 0100, 0010, 0001.
2. Then it returns to 1000.
3. That is 4 states, one per flip-flop.
Common mistake: Assuming every 4-flip-flop counter uses all 2⁴ = 16 states, option (A).
You need: Ring counter
Q.3
EasyNAT1 mark
A Johnson (twisted-ring) counter is built from 5 flip-flops. Its modulus is ______.
Numerical answer: type a number.
Show answer and solutionHide answer and solution
Answer: 10
Key idea: A Johnson counter of n flip-flops has 2n states.
1. In a Johnson counter the inverted last output feeds the first flip-flop.
2. It fills with 1s in 5 clocks and empties in 5 more.
3. So it has 2 × 5 = 10 states.
Common mistake: Using the ring-counter rule (n states) gives 5.
You need: Johnson counter
Q.4
EasyMCQ1 mark
A 4-bit ripple (asynchronous) counter uses flip-flops with a clock-to-Q delay of 10 ns each. The worst-case time for all outputs to settle after a clock edge is
Show answer and solutionHide answer and solution
Answer: (A)
Key idea: Ripple counter delay grows with the number of stages.
1. In a ripple counter each flip-flop is clocked by the previous flip-flop's output.
2. In the worst case (for example 0111 → 1000) the change passes through all 4 stages. 3. 4 × 10 = 40 ns.
Common mistake: Treating it like a synchronous counter, where all flip-flops switch together, gives 10 ns, option (B).
You need: Ripple counters, propagation delay
Q.5
EasyMCQ1 mark
A 4-bit serial-in, parallel-out shift register shifts once per clock: new data enters Q3 and each bit moves from Q3 toward Q0. Starting from 0000, the serial bits 1, 0, 1, 1 are applied in that order, one per clock. After 4 clocks, Q3 Q2 Q1 Q0 is
Show answer and solutionHide answer and solution
Answer: (C)
Key idea: In a shift register, the first bit in travels farthest.
1. Clock 1: 1000.
2. Clock 2: 0100.
3. Clock 3: 1010.
4. Clock 4: 1101.
5. The first bit sent (1) has reached Q0 and the last (1) is in Q3.
Common mistake: Writing the bits in the order they were sent, 1011, option (A), which puts the first bit in Q3.
You need: Shift registers
Q.6
MediumNAT2 marks
A 4-bit synchronous binary up counter (Q3 is the MSB) has an asynchronous active-LOW clear. A 2-input NAND gate with inputs Q3 and Q1 drives the clear. Starting from 0000, the modulus of the counter is ______.
Numerical answer: type a number.
Show answer and solutionHide answer and solution
Answer: 10
Key idea: With an asynchronous clear, the decoded state is only a glitch, not a counted state.
1. The NAND output goes LOW when Q3 = Q1 = 1, which first happens at 1010 (10).
2. The asynchronous clear resets the counter to 0000 at once, so 1010 lasts only a few nanoseconds.
3. The stable states are 0 to 9: modulus 10.
Common mistake: Counting the momentary state 1010 as a full state gives 11.
You need: Counters with asynchronous clear
Q.7
MediumMCQ2 marks
A 100 kHz clock drives a mod-5 counter. The counter's most significant output drives a T flip-flop with T = 1 that toggles once per mod-5 cycle. The frequency at the T flip-flop's output is
Show answer and solutionHide answer and solution
Answer: (D)
Key idea: Cascaded counters divide the frequency by the product of their moduli.
1. The mod-5 counter's MSB completes one cycle every 5 input clocks: 100 ÷ 5 = 20 kHz.
2. The T flip-flop divides by 2 again: 20 ÷ 2 = 10 kHz.
Common mistake: Stopping after the mod-5 stage gives 20 kHz, option (A).
You need: Frequency division, cascaded counters
Q.8
MediumMCQ2 marks
Three positive-edge D flip-flops Q2 Q1 Q0 have D2 = Q1, D1 = Q0 and D0 = (Q2 + Q1)′. Starting from 000, the sequence of states Q2 Q1 Q0 is
Show answer and solutionHide answer and solution
Answer: (B)
Key idea: For any synchronous counter, apply the next-state equations to each state in turn.
1. 000: D2 = 0, D1 = 0, D0 = (0 + 0)′ = 1 → 001. 2. 001: D0 = 1 → 011. 3. 011: D0 = (0 + 1)′ = 0 → 110. 4. 110: D0 = (1 + 1)′ = 0 → 100. 5. 100: D0 = (1 + 0)′ = 0 → 000.
Common mistake: Reading D0 as a NAND, (Q2Q1)′, gives 000, 001, 011, 111, 110, 100 and then 001, option (A).
You need: Synchronous counters, next-state equations
Q.9
MediumNAT1 mark
An 8-bit shift register is loaded serially with a 2 MHz shift clock, one bit per clock. The time to load all 8 bits is ______ µs.
Numerical answer: type a number.
Show answer and solutionHide answer and solution
Answer: 4
Key idea: Serial loading takes one clock per bit.
1. One bit per clock period of 1 ÷ 2 MHz = 0.5 µs. 2. 8 bits × 0.5 µs = 4 µs.
Common mistake: Taking one clock period, 0.5 µs, as the whole load time.
You need: Shift registers, serial transfer
Q.10
MediumMCQ1 mark
A 4-bit Johnson counter shifts from Q3 toward Q0 and feeds Q0′ into Q3. Starting from Q3 Q2 Q1 Q0 = 0000, its state after 6 clocks is
Show answer and solutionHide answer and solution
Answer: (C)
Key idea: A Johnson counter fills with 1s, then empties, one bit per clock.
1. Clock 1: 1000.
2. Clock 2: 1100.
3. Clock 3: 1110.
4. Clock 4: 1111.
5. Clock 5: 0111.
6. Clock 6: 0011.
Common mistake: Stopping one clock early gives 0111, option (A).
You need: Johnson counter
Q.11
MediumMSQ2 marks
Which of the following statements about a 3-bit ripple (asynchronous) up counter made of toggle flip-flops are true?
One or more options are correct.
Show answer and solutionHide answer and solution
Answer: (B), (C) and (D)
Key idea: Ripple counters are simple but slow and glitchy because the stages switch in turn.
1. The settling time grows with the number of stages, so (A) is false.
2. Each later flip-flop is clocked by the previous output, so (B) is true.
3. The bits change one after another, so wrong codes appear briefly, (C) true.
4. Every stage is a toggle stage, (D) true.
Common mistake: Assuming all stages switch at once, as in a synchronous counter, and choosing (A).
You need: Ripple counters
Q.12
MediumMCQ2 marks
A 3-bit ripple up counter (Q2 Q1 Q0, Q0 clocked by the system clock) goes from 011 to 100. The transient states it passes through, in order, are
Show answer and solutionHide answer and solution
Answer: (A)
Key idea: In a ripple counter the change travels from the LSB upward.
1. Q0 toggles first: 011 → 010.
2. Q0 falling clocks Q1, which toggles: 010 → 000.
3. Q1 falling clocks Q2: 000 → 100.
Common mistake: Assuming the MSB changes first gives 111 and then 101, option (B).
You need: Ripple counters, glitches
Q.13
HardNAT2 marks
A 4-bit linear feedback shift register shifts from Q3 toward Q0 on each clock, and the new Q3 is Q2 ⊕ Q0 (taken before the shift). Starting from Q3 Q2 Q1 Q0 = 1000, the number of clocks until the register first returns to 1000 is ______.
Numerical answer: type a number.
Show answer and solutionHide answer and solution
Answer: 6
Key idea: An LFSR reaches the maximum length 2ⁿ − 1 only for particular tap choices.
1. 1000 → (Q2 ⊕ Q0 = 0) 0100. 2. 0100 → (1 ⊕ 0 = 1) 1010. 3. 1010 → (0 ⊕ 0 = 0) 0101. 4. 0101 → (1 ⊕ 1 = 0) 0010. 5. 0010 → (0 ⊕ 0 = 0) 0001. 6. 0001 → (0 ⊕ 1 = 1) 1000.
7. Back to 1000 after 6 clocks.
Common mistake: Assuming every 4-bit LFSR runs through all 15 nonzero states gives 15.
You need: Linear feedback shift registers
Q.14
HardMCQ2 marks
Three positive-edge D flip-flops Q2 Q1 Q0 have D2 = Q1 ⊕ Q0, D1 = Q2′ and D0 = Q1. Which statement describes the state diagram?
Show answer and solutionHide answer and solution
Answer: (D)
Key idea: Always check the unused states of a counter: one may lock up instead of returning to the main cycle.
1. From 000: 010, 111, 001, 110, 101, 100 and back to 000, which is 7 states.
2. The only state left is 011.
3. In 011, D2 = 1 ⊕ 1 = 0, D1 = (0)′ = 1, D0 = 1, so the next state is 011 again: a lockup state.
Common mistake: Assuming the unused state falls back into the main cycle without computing it gives option (B).
You need: Synchronous counters, lockout, self-starting
Q.15
HardMSQ2 marks
A 3-bit synchronous binary up counter is used to make a divide-by-6 circuit. Which of the following statements are true?
One or more options are correct.
Show answer and solutionHide answer and solution
Answer: (A), (B) and (D)
Key idea: A synchronous clear decodes the last wanted state; an asynchronous clear decodes the first unwanted state.
1. Synchronous clear at 101: states 0 to 5, then 0, so 6 states and (A) is true.
2. Asynchronous clear at 110: 110 lasts only a moment, leaving 0 to 5 stable, so (B) is true.
3. Q2 is 1 only in states 4 and 5, 2 of 6 clocks, a duty cycle of 33%, so (C) is false.
4. Q2 rises once per 6 clocks, so (D) is true.
Common mistake: Assuming any divide-by-N output is a square wave and choosing (C).
You need: Counter design, synchronous and asynchronous clear
Past GATE questions on this topic
- GATE 2024 EC, Q.42: Counter state sequence (2 marks, MCQ)
- GATE 2026 EC, Q.27: Ripple counters (1 mark, MSQ)
- GATE 2026 EC, Q.49: Shift registers (2 marks, MCQ)