Difficulty: Easy
Correct Answer: 4
Explanation:
Introduction / Context:
An encoder converts one of many active input lines into a coded binary output. A standard 8-to-3 encoder maps 8 inputs to a 3-bit code. By cascading two such encoders and adding a stage that indicates which block is active, designers can realize a 16-to-4 encoder. This question tests recognition of how output bit width scales with the number of encoded inputs.
Given Data / Assumptions:
Concept / Approach:
The number of output bits required for an encoder is the minimum n such that 2^n ≥ number_of_inputs. For 16 inputs, 2^4 = 16, so 4 output bits are required. In practice, three bits come from the selected 8-to-3 encoder and one additional bit identifies which 8-line block is active.
Step-by-Step Solution:
Determine required bits: find n with 2^n ≥ 16 → n = 4.Use two 8-to-3 encoders: each outputs 3 bits for its 8 inputs.Add a block-select bit: this is the most significant bit indicating upper or lower block.Combine: 1 block-select bit + 3 code bits = 4 total outputs.
Verification / Alternative check:
Label inputs I0–I7 to encoder A and I8–I15 to encoder B. The block-select output is 0 for I0–I7 and 1 for I8–I15. The lower 3 bits come from the active encoder. This yields a 4-bit binary code uniquely identifying any of the 16 inputs.
Why Other Options Are Wrong:
Common Pitfalls:
Forgetting the extra block-select bit when combining smaller encoders, or assuming the 3-bit outputs alone suffice for 16 inputs.
Final Answer:
4
Discussion & Comments