Prev Problem
Next Problem

68. 4-bit Comparator

Compute the maximum and minimum among four unsigned 4-bit inputs.

Requirements

  • Module: maxmin4
  • Inputs: a[3:0], b[3:0], c[3:0], d[3:0]
  • Outputs: max[3:0], min[3:0]
  • Keep it fully combinational (no clocks, no delays).

Behavior

  • Inputs: a[3:0], b[3:0], c[3:0], d[3:0]
  • Outputs: max[3:0], min[3:0]
  • Unsigned comparison. Pairwise tree is recommended