Practice

Combinational circuit design problems

Combinational blocks are the vocabulary of every larger design. These problems build each one from gates, then build bigger ones out of smaller ones: a 4 to 1 mux from three 2 to 1 muxes, a 4 to 16 decoder from 2 to 4 decoders.

146 problems18 free to solve29 easy, 76 medium, 41 hard

The RTL problems write the same blocks in Verilog, where the questions shift to priority, defaults and the latches a missing else infers.

What these problems cover

  • Multiplexers, and any function built from one
  • Decoders and encoders with enables, and cascading them
  • Priority encoders
  • Magnitude comparators
  • Code converters and seven segment decoders
  • Combinational always blocks without inferred latches

Free to start

Solve these with a free account. Every other statement on this page is free to read.

Problems by track

Combinational Building Blocks42

30 more in the Combinational Building Blocks track

Combinational RTL15

3 more in the Combinational RTL track

Digital Foundations1

Gate-Level Logic1

Latches and Flip-Flops2

Counters6

Shift Registers13

1 more in the Shift Registers track

Finite State Machines2

Arithmetic and ALU Design5

Datapath and Storage7

Clocking and Synchronization6

Fault Testing and Verification5

Interface and Communication Circuits3

Interview Circuit1

Verilog Syntax and Language Basics1

Synthesis Intuition2

Datapath Design4

Pipelining1

Clock Domain Crossing and Synchronization1

Interview Circuit1

More problems27

How your answer is checked

Circuit problems run on the circuit simulator against the problem's test vectors, clocked cycle by cycle when they are sequential. Verilog problems are compiled with Icarus Verilog and run against a testbench, with the waveform and the Yosys schematic beside the result. Analysis questions are checked against their answer key.

Questions

How is a combinational circuit checked?
Against its truth table. Circuit problems run every input combination the test vectors list; Verilog problems run the testbench and show each case you got wrong.
Why does my Verilog mux synthesize a latch?
An output not assigned on every path through a combinational always block has to remember its old value. Give it a default or cover every case, and the schematic view will show the latch disappear.