B CompE Bachelor of Computer Engineering Digital Logic Design 1 — Questions and Answers
Question 1: What is the output of an AND gate when both inputs are 1?
- 0
- 1 (Correct answer)
- Undefined
- Depends on voltage
Correct answer: 1
An AND gate outputs 1 (HIGH) only when all of its inputs are 1; with both inputs at 1, the output is 1.
Question 2: Which Boolean expression represents De Morgan's first theorem?
- (A·B)' = A'·B'
- (A+B)' = A'·B'
- (A·B)' = A'+B' (Correct answer)
- (A+B)' = A'+B'
Correct answer: (A·B)' = A'+B'
De Morgan's first theorem states that the complement of a product (NAND) equals the sum of the complements: (A·B)' = A' + B'.
Question 3: How many bits are in one hexadecimal digit?
- 2
- 4 (Correct answer)
- 8
- 16
Correct answer: 4
One hexadecimal digit represents exactly 4 bits, since hex uses base 16 and 2^4 = 16 possible values (0–F).
Question 4: What is the 2's complement representation of -5 in an 8-bit system?
- 11111010
- 10000101
- 11111011 (Correct answer)
- 00000101
Correct answer: 11111011
To find 2's complement of -5: 5 = 00000101, invert to get 11111010, then add 1 to get 11111011.
Question 5: Which logic gate produces an output of 1 only when the number of 1 inputs is odd?
- OR gate
- AND gate
- XNOR gate
- XOR gate (Correct answer)
Correct answer: XOR gate
An XOR (exclusive OR) gate outputs 1 when an odd number of its inputs are 1, making it useful in parity checking and addition circuits.
Question 6: What is the purpose of a Karnaugh Map (K-Map)?
- To simulate digital circuits visually
- To simplify Boolean expressions by grouping minterms (Correct answer)
- To convert decimal numbers to binary
- To design sequential logic circuits
Correct answer: To simplify Boolean expressions by grouping minterms
A Karnaugh Map is a graphical method for simplifying Boolean expressions by visually grouping adjacent minterms to minimize the number of logic gates needed.
What is the output of an AND gate when both inputs are 1?