Chapter 5: Number System and Digital Logic (Set-7)
A number system that uses base 2 and represents data using two stable states in circuits is mainly called which system in computing?
A Decimal system
B Binary system
C Octal system
D Hex system
Computers use two voltage states, so base-2 representation fits naturally. Binary uses digits 0 and 1, making it ideal for storage, processing, and digital logic operations.
In hexadecimal representation, the digit ‘C’ is used frequently in memory dumps. What decimal value does ‘C’ represent?
A Ten value
B Eleven value
C Twelve value
D Thirteen value
Hexadecimal digits extend decimal digits by using A–F. Here A=10, B=11, C=12, D=13, E=14, and F=15, so C equals 12 in decimal.
When writing 0b1011 in programming, the prefix is used to clearly indicate which base for correct interpretation?
A Base two
B Base eight
C Base ten
D Base sixteen
The prefix “0b” is a common notation for binary literals. It prevents confusion with decimal numbers and tells the compiler or reader that the digits are in base-2.
In number conversion, grouping binary bits into sets of three helps convert quickly into which number system without long division?
A Decimal system
B Hex system
C Octal system
D BCD system
One octal digit represents exactly three binary bits because 2³=8. So grouping binary from the right into 3-bit chunks gives direct octal conversion.
While converting binary to hexadecimal quickly, bits are grouped from the right side into sets of how many bits per group?
A Two bits
B Three bits
C Eight bits
D Four bits
One hexadecimal digit corresponds to 4 bits since 2⁴=16. Therefore binary is grouped into 4-bit chunks (nibbles) for fast binary-to-hex conversion.
Which statement correctly describes the range of an unsigned n-bit number used in many basic digital registers?
A 0 to 2ⁿ−1
B −2ⁿ to 2ⁿ
C −2ⁿ⁻¹ to 2ⁿ⁻¹
D 1 to 2ⁿ
Unsigned representation uses all bits for magnitude only. Therefore minimum is 0 and maximum is all 1s, which equals 2ⁿ−1 for n bits.
A 2’s complement system is preferred in computers mainly because it allows subtraction to be performed using what single operation?
A Only shifting
B Only division
C Only addition
D Only AND
In 2’s complement, A−B is done by adding A with the 2’s complement of B. The same adder hardware can do both addition and subtraction.
In 2’s complement method, the step performed after taking 1’s complement of a binary number is to add what value to it?
A Add 1
B Add 0
C Add 2
D Add 10
2’s complement is formed by inverting all bits and then adding 1. This creates a unique zero and makes signed arithmetic easier for digital circuits.
In 1’s complement representation, a special issue occurs because zero can be represented in how many different ways?
A One way
B Two ways
C Three ways
D Four ways
1’s complement has +0 as all zeros and −0 as all ones. This double representation complicates comparisons and arithmetic, which is why 2’s complement is preferred.
In signed 2’s complement numbers, the most significant bit is primarily used to show what information about the number?
A Parity status
B Decimal weight
C Gate output
D Sign of value
The MSB acts as sign bit in 2’s complement: 0 means non-negative and 1 means negative. The remaining bits represent the value using complement rules.
If a binary number is shifted left by one position, the numeric value is generally multiplied by which factor (ignoring overflow)?
A Multiply by 2
B Multiply by 1
C Multiply by 8
D Multiply by 16
Left shift moves bits to higher place values. Since each position in binary is a power of 2, shifting left by one multiplies the number by 2.
If a binary number is shifted right by one position, the numeric value is generally divided by which factor (ignoring fractions)?
A Divide by 8
B Divide by 10
C Divide by 2
D Divide by 16
Right shift moves bits to lower place values. This effectively divides the number by 2 (for unsigned), discarding any remainder bit that shifts out.
In a 2-input truth table, how many total input combinations must be listed to cover all possibilities?
A Two combos
B Four combos
C Three combos
D Eight combos
Each input can be 0 or 1. With two inputs, total combinations are 2² = 4, so four rows are required in the truth table.
A logic gate that gives output 1 only when both inputs are 0 is which gate?
A NAND gate
B XOR gate
C AND gate
D NOR gate
NOR is NOT(OR). OR gives 1 when any input is 1. So NOR becomes 1 only when both inputs are 0.
The NAND gate output becomes 0 only in which input condition for a 2-input NAND?
A Inputs 00
B Inputs 01
C Inputs 11
D Inputs 10
NAND is NOT(AND). AND is 1 only for 11, so NAND becomes 0 only when both inputs are 1. For all other inputs, NAND outputs 1.
A gate often used for equality checking because it outputs 1 when both inputs match is called?
A XNOR gate
B XOR gate
C OR gate
D NOT gate
XNOR outputs 1 when inputs are equal (00 or 11). This makes it useful for comparators and matching logic in digital circuits.
The Boolean identity law for AND states that A·1 equals which simplified result?
A 0
B A
C 1
D A’
AND with 1 does not change the value, so A·1 = A. This rule helps simplify Boolean expressions and reduce unnecessary gates.
According to absorption law, the expression A + A·B simplifies to which output?
A B only
B A·B
C A only
D A+B
If A is 1, expression is 1 regardless of B. If A is 0, both terms become 0. So A + A·B always equals A.
According to De Morgan’s law, the complement of (A + B) is equal to which expression?
A A’·B’
B A’ + B’
C A·B
D (A·B)’
De Morgan’s law states (A + B)’ = A’·B’. This helps transform OR-NOT structures into AND of complemented inputs, useful for NAND/NOR conversions.
The rule (A·B)’ = A’ + B’ is an example of which Boolean concept?
A Commutative law
B De Morgan law
C Null law
D Identity law
De Morgan’s laws convert complements of AND/OR into OR/AND of complements. They are heavily used in simplifying expressions and changing gate implementations.
A Karnaugh map mainly helps in digital logic by doing what task more easily than algebra alone?
A Text encoding
B Voltage regulation
C Image conversion
D Expression simplification
K-maps visually group adjacent 1s or 0s to eliminate variables. This produces simpler Boolean expressions with fewer gates, reducing cost and complexity.
In K-map grouping, a valid group size must always be which kind of number?
A Any number
B Prime number
C Power of two
D Odd number
Groups must contain 1, 2, 4, 8, etc. cells. This structure ensures variables cancel correctly, giving a valid simplified term.
A half adder circuit adds two single-bit numbers and produces sum and carry. Which gate gives its sum output?
A XOR gate
B OR gate
C AND gate
D NOR gate
For a half adder, sum is 1 when inputs differ, which matches XOR behavior. Carry occurs only when both are 1, matching AND behavior.
A full adder can be built using two half adders and an additional gate to combine carries. Which gate commonly combines the carries?
A XOR gate
B NAND gate
C OR gate
D XNOR gate
Two half adders produce two carry signals. OR gate combines them to form final carry-out, ensuring carry becomes 1 if any carry path is active.
A multiplexer is used to select one of many inputs and send it to one output. What controls the selection?
A Clock pulses
B Select lines
C Parity bits
D MSB lines
Select lines form a binary code that chooses which input line is connected to the output. More inputs require more select lines (log₂ of inputs).
A demultiplexer takes one input and routes it to one of many outputs. What decides which output gets the signal?
A Base value
B Hex digits
C Carry bit
D Select lines
The select lines of a demultiplexer choose the output path for the input signal. It works like a controlled distributor, sending data to one selected output.
In a decoder, an n-bit binary input activates typically how many output lines at a time in normal operation?
A One line
B All lines
C Two lines
D Four lines
A decoder usually produces a one-hot output. For each input combination, exactly one output line becomes active, useful for address selection and device enabling.
An encoder converts a single active input line into a coded output. Which type is used when multiple inputs may be active?
A Plain encoder
B Gray encoder
C Priority encoder
D BCD encoder
When multiple inputs are active, a priority encoder selects the highest-priority input and outputs its code. This avoids ambiguity and is common in interrupt systems.
ASCII is a standard code mainly designed to represent which type of data in computers?
A Decimal fractions
B Logic gates
C Power levels
D Text characters
ASCII assigns numeric codes to letters, digits, punctuation, and control characters. This allows computers to store and transmit text in a standard, compatible format.
BCD is used in many display systems because it represents each decimal digit using how many bits?
A Four bits
B Two bits
C Three bits
D Eight bits
BCD encodes each decimal digit 0–9 using 4 bits. This helps digital displays show decimal digits directly without complex binary-to-decimal conversion.
A parity bit is added to a data word mainly to support which basic function in communication?
A Data encryption
B Error detection
C Data compression
D Speed boosting
Parity adds one extra bit to detect many single-bit errors. If one bit flips, parity becomes wrong, alerting the receiver that an error likely occurred.
If even parity is used and the data already contains an even number of 1s, the parity bit should be set to which value?
A Set to 1
B Set to 2
C Set to 0
D Set to 8
Even parity requires total number of 1s (data + parity) to be even. If data already has even 1s, parity bit stays 0 to keep total even.
A major limitation of simple parity checking is that it may fail when errors occur in which pattern?
A Two-bit error
B Single-bit error
C No-bit error
D MSB error
Parity detects odd numbers of bit flips. If two bits flip, total parity may remain unchanged, so the parity check can miss that error.
In BCD arithmetic, if a 4-bit sum exceeds 9, a correction is applied by adding which value?
A Add 3
B Add 5
C Add 9
D Add 6
BCD digits must remain 0–9. If sum is 10–15 or a carry occurs, adding 6 (0110₂) adjusts it into a valid BCD representation.
A flip-flop is considered a basic building block of sequential circuits because it stores how much information?
A Two bits
B Four bits
C One bit
D Eight bits
Flip-flops are memory elements that hold one binary state (0 or 1). They form registers, counters, and many sequential systems used in digital electronics.
A latch differs from an edge-triggered flip-flop mainly because a latch is sensitive to which condition?
A Level enable
B Voltage limit
C Hex digits
D Parity rule
Latches are level-sensitive, meaning output can change while enable is active. Flip-flops are typically edge-triggered, changing only at a clock edge.
In a JK flip-flop, when J = 1 and K = 1, what happens at each active clock event?
A Set output
B Toggle output
C Reset output
D Hold output
JK flip-flop resolves SR invalid state. With J=K=1, it toggles Q at each clock edge, making it useful for counters and frequency division.
In a D flip-flop, the next output state after clock edge is mainly equal to what value?
A Previous Q
B NOT D
C D input
D Carry out
A D flip-flop captures the D input at the active clock edge. After the edge, output Q becomes equal to D and holds until next clock event.
A basic classification says a circuit is combinational when its output depends on only what factor?
A Present inputs
B Past history
C Clock count
D Stored parity
Combinational circuits have no memory, so outputs depend only on current input values. Examples include adders, multiplexers, and decoders.
A sequential circuit differs from combinational because it depends on present inputs and also what additional factor?
A Power supply
B Screen size
C File format
D Past state
Sequential circuits include memory elements like flip-flops. Therefore outputs depend on current inputs plus previously stored state, which changes only with clock/control signals.
Converting a binary number to decimal is usually done by summing which weights of positions?
A Powers of 10
B Powers of 8
C Powers of 2
D Powers of 16
Binary is base-2. Each bit position has weight 2⁰, 2¹, 2², etc. Add weights where bits are 1 to get the decimal value.
The binary number 10000000₂ represents decimal 128 in unsigned form. In 8-bit 2’s complement, the same pattern represents which value?
A −128
B +127
C −127
D +128
In 8-bit 2’s complement, MSB=1 means negative. Pattern 10000000₂ is the most negative value and equals −128, due to range −128 to +127.
When extending a negative 2’s complement number to more bits, which action preserves its value correctly?
A Add zeros left
B Repeat sign bit
C Flip all bits
D Add parity bit
Sign extension copies the MSB into new left bits. For negative numbers, MSB is 1, so extending with 1s keeps the numeric value unchanged in 2’s complement.
A common way to implement NOT using only NAND gates is by connecting its inputs in what manner?
A Inputs separate
B Input left open
C Inputs grounded
D Inputs tied same
If both NAND inputs are connected to the same signal A, output becomes NOT(A) because NAND(A,A) = (A·A)’ = A’.
A common way to implement NOT using only NOR gates is by connecting its inputs in what manner?
A Inputs different
B Inputs floating
C Inputs tied same
D Inputs inverted
If both NOR inputs are connected to A, output becomes NOR(A,A) = (A + A)’ = A’. This provides an inverter using a single NOR gate.
In binary subtraction, the borrow concept means the next higher bit contributes what value to the current bit place?
A Adds 1
B Adds 2
C Adds 8
D Adds 16
Borrowing from the next higher bit means taking 1 from that position, which equals 2 in the current position (since weights double). This enables subtraction at the lower bit.
In binary multiplication, multiplying any number by 1 gives the same number, and multiplying by 0 gives zero. This is because each multiplier bit is only what?
A 0 or 1
B 0 to 9
C A to F
D Any digit
Binary digits are only 0 or 1. So partial products are either all zeros (for 0) or a shifted copy of multiplicand (for 1), simplifying multiplication.
In Boolean algebra, the distributive law allows which kind of transformation during simplification?
A Split OR over NOT
B Split NOT over XOR
C Split AND over OR
D Split XOR over AND
Distributive law states A·(B+C)=AB+AC. This helps expand or factor expressions to reduce gates and reach SOP or POS forms efficiently.
A full adder produces carry-out when at least how many of its three inputs are 1?
A Two inputs
B One input
C Three inputs
D Zero inputs
Carry-out becomes 1 if at least two inputs among A, B, and Cin are 1. This matches expression AB + AC + BC, covering all “two-or-more ones” cases.
A logic gate diagram is often verified using a truth table because a truth table provides what complete information?
A Wire length only
B CPU instruction set
C Memory size
D All input cases
A truth table lists output for every possible input combination. This complete mapping helps verify whether a logic expression or gate circuit behaves correctly in all cases.