Sikshya Plus Get appGet the app free
Class 11 · Computer Science

Number System & Ttheir conversion and Boolean Logic – Class 11 Computer Science Notes and Solutions

Complete solutions and answers for “Number System & Ttheir conversion and Boolean Logic”, a chapter in Class 11 Computer Science (NEB exam preparation). This page covers Number Systems & Boolean Algebra.

  • Free, no login needed
  • 29 min read
  • Updated 1 July 2026

Chapter at a glance

This chapter covers the fundamental concepts of number systems, including their conversion between binary, octal, decimal, and hexadecimal. It also delves into Boolean algebra, logic gates, and their operations, providing a comprehensive understanding of digital logic.

  • Positional Number Systems
  • Base Conversions (Binary, Octal, Decimal, Hexadecimal)
  • Binary Arithmetic (Addition, Subtraction)
  • Complement Methods (1's and 2's Complement)
  • Boolean Algebra
  • Logic Gates (AND, OR, NOT, NAND, NOR, XOR, XNOR)
  • De Morgan's Theorems
  • Boolean Function and Truth Tables

Exam focus: Students should focus on understanding number system conversions, performing binary arithmetic, and applying Boolean algebra principles to logic gates and their operations, including De Morgan's theorems.

Key formulas and definitions

  • Base-n to Decimal: Sum of (digit × base^position)
  • Decimal to Base-n: Repeated division/multiplication
  • Binary to Octal: Group bits in threes
  • Binary to Hexadecimal: Group bits in fours
  • Boolean Algebra Laws (Commutative, Distributive, Duality, De Morgan's)
On this page (33 sections)
  1. Number Systems & Boolean Algebra
  2. Q1. What is a number system? Why is the binary number system used in digital computers?
  3. Q2. Explain shortly about the four number systems.
  4. Q3. Convert binary numbers to decimal
  5. Q4. Convert decimal numbers to binary
  6. Q5. Convert octal numbers to decimal
  7. Q6. Convert decimal numbers to octal
  8. Q7. Convert hexadecimal numbers to decimal
  9. Q8. Convert decimal numbers to hexadecimal
  10. Q9. Convert binary numbers to octal
  11. Q10. Convert octal numbers to binary
  12. Q11. Convert binary numbers to hexadecimal
  13. Q12. Convert hexadecimal numbers to binary
  14. Q13. Convert as indicated (mixed conversions)
  15. Q14. Perform binary addition
  16. Q15. Perform binary subtraction
  17. Q16. Decimal subtraction using 9's complement method
  18. Q17. Decimal subtraction using 10's complement method
  19. Q18. Binary subtraction using 1's complement method
  20. Q19. Binary subtraction using 2's complement method
  21. Q20. What is Boolean algebra? Differentiate OR gate and AND gate.
  22. Q21. What is a Boolean function? Write the Truth Table of Ex-OR gate.
  23. Q22. What is a logic gate? Explain the NAND gate with Truth Table.
  24. Q23 & Q24. Differentiate between NAND and NOR gates
  25. Q25. Differentiate between XOR gate and XNOR gate
  26. Q26. What is the duality principle?
  27. Q27. State and prove the Commutative Law
  28. Q28. State and prove the Distributive Law
  29. Q29. State and prove De Morgan's Theorems
  30. Q30. Draw the Venn diagram of AND, OR, and NOT gates
  31. Long Q1. What is Boolean algebra? Describe AND, OR, NOT, and NAND gates.
  32. Long Q2. What is a logic gate? Describe any four logic gates.
  33. Long Q3. Describe any five logic gates with Truth Table and gate symbol.

Solutions and answers

Number Systems & Boolean Algebra

Complete solution guide for Innovative Computer Science, Grade 11 — covering positional number systems, base conversions, binary arithmetic, complement subtraction, and all Boolean algebra & logic gate concepts with fully worked examples.

Number Systems Binary ↔ Decimal Octal ↔ Hex 1's & 2's Complement Boolean Algebra Logic Gates De Morgan's Theorems
📝
Exercise 1 — Multiple Choice Questions
Choose the correct option with detailed explanations
a. Which of the following is a positional number system?
i. Decimal number system
ii. Roman number system
iii. Unary number system
iv. All of the above
i. Decimal number system
A positional (or weighted) number system assigns a specific weight (power of the base) to each digit based on its position. The decimal system (base-10) is positional: in the number 345, the digit 3 represents 3×10², 4 represents 4×10¹, and 5 represents 5×10⁰. The Roman system (I, V, X, L…) is non-positional — the value of a symbol does not change with its position. The Unary system (tally marks) is also non-positional.
b. Base of the number system is also called...
i. root
ii. prefix
iii. suffix
iv. radix
iv. radix
The radix (or base) of a number system is the total number of unique digits used, including zero. For example, the decimal system has radix 10 (digits 0–9), the binary system has radix 2 (digits 0 and 1), octal has radix 8 (digits 0–7), and hexadecimal has radix 16 (digits 0–9 and A–F).
c. The maximum number of bits sufficient to represent an octal number is...
i. 3
ii. 4
iii. 8
iv. 10
i. 3
Each octal digit (0–7) can be represented by exactly 3 binary digits, because 2³ = 8. For example: 7₈ = 111₂, 3₈ = 011₂, 0₈ = 000₂. This is why binary-to-octal conversion groups bits in threes.
d. A Boolean algebra describes...
i. the logical relations of the Boolean variables
ii. the behavior of logic circuits
iii. the relationship between input and output variables
iv. All of the above
iv. All of the above
Boolean algebra is a mathematical framework introduced by George Boole. It describes (i) the logical relationships between variables that can only take values 0 or 1, (ii) the behavior of digital logic circuits, and (iii) the input-output relationship of those circuits.
e. A Boolean variable can hold...
i. 0 (zero)
ii. 1 (non-zero)
iii. Both 0 (zero) and 1 (Non-zero)
iv. either 0 (zero) or 1 (non-zero)
iv. either 0 (zero) or 1 (non-zero)
A Boolean (binary) variable has exactly two possible values: 0 (FALSE/LOW) or 1 (TRUE/HIGH). At any given moment it holds one of these — "either 0 or 1" — not both simultaneously. Options (iii) and (iv) are similar in meaning, but (iv) more precisely captures the mutual exclusivity.
f. The basic logic gates are...
i. AND gate, OR gate and NOR gate
ii. AND gate, NOT gate and XOR gate
iii. XOR gate, NOR gate and NAND gate
iv. OR gate, AND gate and NOT gate
iv. OR gate, AND gate and NOT gate
The three basic (universal primitive) gates are AND, OR, and NOT. All other gates (NAND, NOR, XOR, XNOR) can be constructed by combining these three.
g. The AND gate produces result as true when...
i. all the inputs are true
ii. any two inputs are true and other inputs are false
iii. all the inputs are false
iv. None of the above
i. all the inputs are true
The AND gate outputs 1 only when every input is 1. If even a single input is 0, the output is 0. This models logical conjunction: "A AND B is true only if both A and B are true."
h. The AND gate in a Boolean expression is represented by...
i. + (plus) sign
ii. · (multiplication) sign
iii. ' (apostrophe) sign
iv. ⊕ (encircled plus) sign
ii. · (multiplication) sign
In Boolean notation, AND is expressed as multiplication: Y = A · B (also written as AB). The + sign represents OR, the ' (apostrophe / prime) represents NOT (complement), and ⊕ represents XOR.
i. The logical diagram of the OR gate is represented by...
i. D-shaped symbol (AND-style)
ii. Curved input side with pointed output (D shape with curved left)
iii. Triangle with circle (NOT gate)
iv. Diamond shape
ii. Curved input side with pointed output
The OR gate symbol has a curved (concave) input side and a pointed output — resembling an aeroplane or bullet shape. The AND gate has a flat (D-shaped) input side. The NOT gate is a triangle with a small circle at the output.
j. The NAND gate contains...
i. AND gate and NOT gate
ii. OR gate and NOT gate
iii. XOR gate and NOT gate
iv. None of the above
i. AND gate and NOT gate
NAND stands for "NOT AND." A NAND gate is equivalent to an AND gate followed by a NOT gate: Y = A · B. It produces 0 only when all inputs are 1; otherwise it outputs 1.
k. If A and B are inputs and Y is output, then the AND gate is expressed as...
i. Y = A + B
ii. Y = A − B
iii. Y = A · B
iv. Y = A · B
iii. Y = A · B
The AND operation is written as Y = A · B (or simply Y = AB). "Y = A + B" represents OR, and "Y = A · B" represents NAND.
l. If A and B are inputs, then the NAND gate is expressed as...
i. A + B
ii. A NAND B
iii. A NOT AND B NOT
iv. All of the above
ii. A NAND B
The NAND gate is expressed as A NAND B, or more formally as A · B. "A + B" is OR, and "A NOT AND B NOT" is not a correct Boolean expression. The standard symbol for NAND is an AND gate with a small circle (bubble) at the output.
m. An XOR gate yields a high output when...
i. both inputs are false
ii. both inputs are true
iii. inputs are different
iv. None of the above
iii. inputs are different
XOR (Exclusive OR) produces 1 when the inputs differ: (0,1) or (1,0). It produces 0 when inputs are the same: (0,0) or (1,1). Boolean expression: Y = A ⊕ B = AB + AB.
n. An XNOR gate yields the result as true if...
i. both inputs are false
ii. one input is true
iii. inputs are the same
iv. None of the above
iv. None of the above (inputs are the same)
XNOR is the complement of XOR. It produces 1 when inputs are the same: (0,0) → 1 and (1,1) → 1. Option i gives only one case (0,0), and option ii describes XOR behavior. Since neither i nor ii completely and correctly describes XNOR, the answer is None of the above. The correct description: "Y = 1 when both inputs are equal."
💡
Short Answer Questions — Concepts & Definitions
Questions 1–2: Number systems, decimal, binary, octal, hexadecimal

Q1. What is a number system? Why is the binary number system used in digital computers?

Number System: A number system is a systematic method of representing (expressing) numbers using a consistent set of digits or symbols and a defined base (radix). The base determines how many unique symbols are used and how each position's weight is calculated.

Common number systems include:

  • Decimal (base-10): Uses digits 0–9. Everyday human counting system.
  • Binary (base-2): Uses digits 0 and 1. Foundation of all digital computing.
  • Octal (base-8): Uses digits 0–7. Convenient shorthand for binary.
  • Hexadecimal (base-16): Uses digits 0–9 and A–F. Widely used in programming.
Why Binary in Digital Computers?
  • Hardware simplicity: Electronic circuits have two stable states — ON (high voltage / 1) and OFF (low voltage / 0). These naturally map to the two binary digits.
  • Reliability: Distinguishing between two states is far more reliable than distinguishing ten voltage levels (as needed for decimal), reducing errors from noise.
  • Cost-effectiveness: Designing circuits with two states requires simpler, cheaper, and more compact components.
  • Logical operations: Boolean algebra (with values TRUE=1 and FALSE=0) maps perfectly to binary, enabling all arithmetic and logic operations.
  • Universal compatibility: All data — numbers, text, images, sound — can be encoded as sequences of 0s and 1s.

Q2. Explain shortly about the four number systems.

a. Decimal Number System (Base-10)
  • Uses 10 digits: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9.
  • Each position has a weight that is a power of 10.
  • Example: 345.67 = 3×10² + 4×10¹ + 5×10⁰ + 6×10⁻¹ + 7×10⁻²
  • It is the most familiar and widely used system in daily life.
b. Binary Number System (Base-2)
  • Uses only 2 digits: 0 and 1. Each digit is called a bit.
  • Each position has a weight that is a power of 2: … 2³, 2², 2¹, 2⁰, 2⁻¹, 2⁻² …
  • Example: 1101₂ = 1×2³ + 1×2² + 0×2¹ + 1×2⁰ = 8 + 4 + 0 + 1 = 13₁₀
  • It is the native language of all digital computers.
c. Octal Number System (Base-8)
  • Uses 8 digits: 0, 1, 2, 3, 4, 5, 6, 7.
  • Each position has a weight that is a power of 8.
  • Each octal digit corresponds to exactly 3 binary digits (since 2³ = 8).
  • Example: 257₈ = 2×8² + 5×8¹ + 7×8⁰ = 128 + 40 + 7 = 175₁₀
  • Used as a compact representation of binary numbers (e.g., file permissions in Unix).
d. Hexadecimal Number System (Base-16)
  • Uses 16 symbols: 0–9 and A–F (where A=10, B=11, C=12, D=13, E=14, F=15).
  • Each position has a weight that is a power of 16.
  • Each hex digit corresponds to exactly 4 binary digits (since 2⁴ = 16).
  • Example: 2AF₁₆ = 2×16² + 10×16¹ + 15×16⁰ = 512 + 160 + 15 = 687₁₀
  • Widely used in computer science for memory addresses, colour codes (#FF0000), and machine code.
🔄
Questions 3–13 — Number System Conversions
Binary ↔ Decimal ↔ Octal ↔ Hexadecimal with fully worked steps
📖 Quick Reference — Conversion Methods
  • Base-n → Decimal: Sum of (digit × baseposition) for every digit.
  • Decimal → Base-n: For the integer part, repeatedly divide by n and collect remainders (bottom → top). For the fractional part, repeatedly multiply by n and collect integer parts (top → bottom).
  • Binary → Octal: Group bits in threes (from the radix point outward), convert each group.
  • Binary → Hexadecimal: Group bits in fours, convert each group.
  • Octal/Hex → Binary: Expand each digit to 3 or 4 bits respectively.

Q3. Convert binary numbers to decimal

#BinaryExpansion (powers of 2)Decimal Result
a.11011 1×2⁴ + 1×2³ + 0×2² + 1×2¹ + 1×2⁰ = 16+8+0+2+1 27
b.10010 1×2⁴ + 0×2³ + 0×2² + 1×2¹ + 0×2⁰ = 16+0+0+2+0 18
c.10101 1×2⁴ + 0×2³ + 1×2² + 0×2¹ + 1×2⁰ = 16+0+4+0+1 21
d.110110 1×2⁵+1×2⁴+0×2³+1×2²+1×2¹+0×2⁰=32+16+0+4+2+0 54
e.1111011 1×2⁶+1×2⁵+1×2⁴+1×2³+0×2²+1×2¹+1×2⁰=64+32+16+8+0+2+1 123
f.10111.01 16+0+4+2+1 + 0×2⁻¹+1×2⁻² = 23 + 0+0.25 23.25
g.11011.101 16+8+0+2+1 + 0.5+0+0.125 = 27.625 27.625

Q4. Convert decimal numbers to binary

Method

Integer part: Repeatedly divide by 2, collect remainders (read bottom → top).
Fractional part: Repeatedly multiply by 2, collect integer parts (read top → bottom).

#DecimalWorked StepsBinary Result
a.59 59÷2=29 r1, 29÷2=14 r1, 14÷2=7 r0, 7÷2=3 r1, 3÷2=1 r1, 1÷2=0 r1 111011
b.128 128÷2=64 r0 → 32 r0 → 16 r0 → 8 r0 → 4 r0 → 2 r0 → 1 r0 → 0 r1 10000000
c.85 85÷2=42 r1 → 21 r0 → 10 r1 → 5 r0 → 2 r1 → 1 r0 → 0 r1 1010101
d.268 268÷2=134 r0 → 67 r0 → 33 r1 → 16 r1 → 8 r0 → 4 r0 → 2 r0 → 1 r0 → 0 r1 100001100
e.340 340÷2=170 r0 → 85 r0 → 42 r1 → 21 r0 → 10 r1 → 5 r0 → 2 r1 → 1 r0 → 0 r1 101010100
f.0.28 0.28×2=0.56 → 0.56×2=1.12 → 0.12×2=0.24 → 0.24×2=0.48 → 0.48×2=0.96 → 0.96×2=1.92 … (repeating cycle 10001…) 0.010001 (approx)
g.107.65 Integer: 107 → 1101011. Fractional: 0.65×2=1.30→0.30×2=0.60→0.60×2=1.20→0.20×2=0.40→0.40×2=0.80→0.80×2=1.60 1101011.101001 (approx)

Q5. Convert octal numbers to decimal

Method
Multiply each octal digit by the corresponding power of 8 and sum all products.
#OctalExpansionDecimal
a.103₈1×8² + 0×8¹ + 3×8⁰ = 64+0+367
b.127₈1×8² + 2×8¹ + 7×8⁰ = 64+16+787
c.245₈2×8² + 4×8¹ + 5×8⁰ = 128+32+5165
d.324₈3×8² + 2×8¹ + 4×8⁰ = 192+16+4212
e.366₈3×8² + 6×8¹ + 6×8⁰ = 192+48+6246
f.0.357₈3×8⁻¹ + 5×8⁻² + 7×8⁻³ = 0.375+0.0977+0.01710.48975
g.21.21₈2×8+1 + 2×8⁻¹+1×8⁻² = 17+0.25+0.01562517.265625

Q6. Convert decimal numbers to octal

Method
Integer part: Repeatedly divide by 8, collect remainders (bottom → top).
Fractional part: Repeatedly multiply by 8, collect integer parts.
#DecimalStepsOctal
a.4848÷8=6 r0, 6÷8=0 r660₈
b.215215÷8=26 r7, 26÷8=3 r2, 3÷8=0 r3327₈
c.312312÷8=39 r0, 39÷8=4 r7, 4÷8=0 r4470₈
d.452452÷8=56 r4, 56÷8=7 r0, 7÷8=0 r7704₈
e.784784÷8=98 r0, 98÷8=12 r2, 12÷8=1 r4, 1÷8=0 r11420₈
f.58.5Int: 58÷8=7 r2, 7÷8=0 r7 → 72₈. Frac: 0.5×8=4.072.4₈
g.128.75Int: 128÷8=16 r0, 16÷8=2 r0, 2÷8=0 r2 → 200₈. Frac: 0.75×8=6.0200.6₈

Q7. Convert hexadecimal numbers to decimal

Hex digit values: A=10, B=11, C=12, D=13, E=14, F=15
#HexExpansionDecimal
a.45₁₆4×16¹ + 5×16⁰ = 64+569
b.145₁₆1×16² + 4×16¹ + 5×16⁰ = 256+64+5325
c.AB8₁₆10×16² + 11×16¹ + 8×16⁰ = 2560+176+82744
d.20A₁₆2×16² + 0×16¹ + 10×16⁰ = 512+0+10522
e.BCD₁₆11×16² + 12×16¹ + 13×16⁰ = 2816+192+133021
f.79.A₁₆7×16+9 + 10×16⁻¹ = 121+0.625121.625
g.59.3₁₆5×16+9 + 3×16⁻¹ = 89+0.187589.1875

Q8. Convert decimal numbers to hexadecimal

#DecimalSteps (÷16)Hex
a.232232÷16=14 r8 → 0 r14(E)E8₁₆
b.788788÷16=49 r4 → 3 r1 → 0 r3314₁₆
c.23242324÷16=145 r4 → 9 r1 → 0 r9914₁₆
d.12341234÷16=77 r2 → 4 r13(D) → 0 r44D2₁₆
e.13451345÷16=84 r1 → 5 r4 → 0 r5541₁₆
f.420.5Int: 420÷16=26 r4 → 1 r10(A) → 0 r1 → 1A4₁₆. Frac: 0.5×16=8.01A4.8₁₆

Q9. Convert binary numbers to octal

Method
Group binary digits in threes from the radix point (left and right), then convert each group to its octal equivalent.
#BinaryGrouped (3-bit)Octal
a.11011101011 · 011 · 101335₈
b.1011011001 · 011 · 011133₈
c.10111001010 · 111 · 001271₈
d.10000101010 · 000 · 101205₈
e.1010111001 · 010 · 111127₈
f.1101101.11101001·101·101 . 111·010155.72₈

Q10. Convert octal numbers to binary

Method
Replace each octal digit with its 3-bit binary equivalent.
#OctalEach digit → 3 bitsBinary
a.64₈6=110, 4=100110100
b.72₈7=111, 2=010111010
c.127₈1=001, 2=010, 7=1111010111
d.265₈2=010, 6=110, 5=10110110101
e.456₈4=100, 5=101, 6=110100101110
f.74.31₈7=111, 4=100, 3=011, 1=001111100.011001

Q11. Convert binary numbers to hexadecimal

Method
Group binary digits in fours from the radix point, then convert each group.
#BinaryGrouped (4-bit)Hex
a.1111010100001 · 1110 · 10101EA₁₆
b.1011010010001 · 0110 · 1001169₁₆
c.11110001010011 · 1100 · 01013C5₁₆
d.10010011100010 · 0100 · 111024E₁₆
e.1010110010001 · 0101 · 1001159₁₆
f.10000101.1110011000·0101 . 1110·010085.E4₁₆

Q12. Convert hexadecimal numbers to binary

#HexEach digit → 4 bitsBinary
a.103₁₆1=0001, 0=0000, 3=0011100000011
b.429₁₆4=0100, 2=0010, 9=100110000101001
c.2AD₁₆2=0010, A=1010, D=11011010101101
d.A0C₁₆A=1010, 0=0000, C=1100101000001100
e.BAD₁₆B=1011, A=1010, D=1101101110101101
f.8F.34₁₆8=1000, F=1111, 3=0011, 4=010010001111.001101

Q13. Convert as indicated (mixed conversions)

#GivenMethodResult
a. (A24)₁₆ → (?)₂ A=1010, 2=0010, 4=0100 (101000100100)₂
b. (DOE)₁₆ → (?)₈ D=1101, O→0=0000, E=1110 → 110100001110₂ → group 3: 000·101·000·011·101·110 → 110100001110 → regroup 011·010·000·111·011·10
(corrected): 1101 0000 1110₂ = 011·010·000·111·011·10 → 6416₈
(6416)₈
c. (970)₁₆ → (?)₈ 9=1001, 7=0111, 0=0000 → 100101110000₂ → 010·010·111·000 → 4560₈ (4560)₈
d. (773)₈ → (?)₁₆ 7=111, 7=111, 3=011 → 111111011₂ → 0001·1111·1011 → 1FB₁₆ (1FB)₁₆
e. (3467)₈ → (?)₁₆ 3=011,4=100,6=110,7=111 → 011100110111₂ → 0111·0011·0111 → 737₁₆ (737)₁₆
f. (204)₈ → (?)₁₆ 2=010,0=000,4=100 → 010000100₂ → 0000·1000·0100 → 84₁₆ (84)₁₆
➕
Questions 14 & 15 — Binary Addition & Subtraction
Standard binary arithmetic with carries and borrows

Q14. Perform binary addition

Rules: 0+0=0, 0+1=1, 1+0=1, 1+1=10 (0 carry 1), 1+1+1=11 (1 carry 1).
a. 1100 + 1010
carry: 1 0 1 0 1 1 0 0 + 1 0 1 0 ───────── 1 0 1 1 0 → (26)₁₀
10110₂ = 26₁₀
b. 1111 + 1011
carry: 1 1 1 1 1 1 1 1 + 1 0 1 1 ───────── 1 1 0 1 0 → (26+4=26... actually 15+11=26)₁₀
11010₂ = 26₁₀ (15 + 11 = 26 ✓)
c. 1101 + 1110
11011₂ = 27₁₀ (13 + 14 = 27 ✓)
d. 10111 + 10101
101100₂ = 44₁₀ (23 + 21 = 44 ✓)
e. 10110 + 11001
101111₂ = 47₁₀ (22 + 25 = 47 ✓)
f. 10011 + 11000
101011₂ = 43₁₀ (19 + 24 = 43 ✓)

Q15. Perform binary subtraction

Rules: 0−0=0, 1−0=1, 1−1=0, 0−1=1 (borrow 1 from left).
#OperationDecimal CheckResult
a.1010 − 11110 − 7 = 311₂
b.1100 − 11012 − 6 = 6110₂
c.11000 − 1011124 − 23 = 11₂
d.11101 − 101129 − 11 = 1810010₂
e.11011 − 101127 − 11 = 1610000₂
f.10011 − 110119 − 13 = 6110₂
🧮
Questions 16–19 — Complement Subtraction Methods
9's, 10's, 1's, and 2's complement methods fully worked

Q16. Decimal subtraction using 9's complement method

📖 9's Complement Method
  • Find the 9's complement of the subtrahend (subtract each digit from 9).
  • Add the minuend and the 9's complement of the subtrahend.
  • If there is a carry out: result is positive → add the carry to the sum (end-around carry).
  • If there is no carry: result is negative → take the 9's complement of the sum and attach a minus sign.
a. 789 − 216
9's complement of 216 = 999 − 216 = 783
789 + 783 = 1572 → Carry out! Discard carry and add 1: 572 + 1 = 573
b. 458 − 325
9's complement of 325 = 999 − 325 = 674
458 + 674 = 1132 → Carry! 132 + 1 = 133
c. 1018 − 658
9's complement of 0658 = 9999 − 0658 = 9341
1018 + 9341 = 10359 → Carry! 0359 + 1 = 360
d. 254 − 3546
9's complement of 3546 = 9999 − 3546 = 6453
0254 + 6453 = 6707 → No carry → 9's complement of 6707 = 9999 − 6707 = 3292 → −3292
e. 31 − 541
9's complement of 0541 = 9999 − 0541 = 9458
0031 + 9458 = 9489 → No carry → 9999 − 9489 = 510 → −510
f. 28 − 120
9's complement of 0120 = 9999 − 0120 = 9879
0028 + 9879 = 9907 → No carry → 9999 − 9907 = 92 → −92

Q17. Decimal subtraction using 10's complement method

📖 10's Complement Method
  • Find the 10's complement of the subtrahend = 9's complement + 1.
  • Add the minuend and the 10's complement.
  • If there is a carry out: discard it — the remaining sum is the positive result.
  • If there is no carry: the result is negative — take the 10's complement of the sum.
a. 123 − 58
10's complement of 058 = 1000 − 058 = 942
123 + 942 = 1065 → Carry! Drop it → 65
b. 4521 − 588
10's complement of 0588 = 10000 − 0588 = 9412
4521 + 9412 = 13933 → Carry! → 3933
c. 9855 − 909
10's complement of 0909 = 10000 − 0909 = 9091
9855 + 9091 = 18946 → Carry! → 8946
d. 129 − 1234
10's complement of 1234 = 10000 − 1234 = 8766
0129 + 8766 = 8895 → No carry → 10's complement of 8895 = 10000−8895 = 1105 → −1105
e. 28 − 465
10's complement of 0465 = 10000 − 0465 = 9535
0028 + 9535 = 9563 → No carry → 10000 − 9563 = 437 → −437
f. 710 − 8751
10's complement of 8751 = 10000 − 8751 = 1249
0710 + 1249 = 1959 → No carry → 10000 − 1959 = 8041 → −8041

Q18. Binary subtraction using 1's complement method

📖 1's Complement Method
  • Find the 1's complement of the subtrahend (flip every bit: 0→1, 1→0).
  • Add the minuend and the 1's complement.
  • If there is a carry out: add it back to the result (end-around carry) → positive answer.
  • If there is no carry: result is negative → take the 1's complement of the sum and negate.
a. 1110 − 110
1's complement of 0110 = 1001
1110 + 1001 = 10111 → Carry! → 0111 + 1 = 1000₂ (= 8)
b. 10101 − 1110
1's complement of 01110 = 10001
10101 + 10001 = 101110 → Carry! → 01110 + 1 = 10111₂ (= 23 ... wait, 21−14=7=111₂)
Correction: 10101 + 10001 = 100110 → Carry! → 00110 + 1 = 111₂ (= 7)
c. 11001 − 10111
1's complement of 10111 = 01000
11001 + 01000 = 100001 → Carry! → 00001 + 1 = 10₂ (= 2)
d. 1001 − 1101
1's complement of 01101 = 10010
01001 + 10010 = 11011 → No carry → 1's complement of 11011 = 00100 → −100₂ (= −4)
e. 1001 − 111010
1's complement of 111010 = 000101
001001 + 000101 = 001110 → No carry → 1's complement of 001110 = 110001 → −110001₂ (= −49)
f. 1101 − 11010
1's complement of 11010 = 00101
01101 + 00101 = 10010 → No carry → 1's complement of 10010 = 01101 → −1101₂ (= −13)

Q19. Binary subtraction using 2's complement method

📖 2's Complement Method
  • Find the 2's complement of the subtrahend = 1's complement + 1 (flip all bits, add 1).
  • Add the minuend and the 2's complement.
  • If there is a carry out: discard it → the result is positive.
  • If there is no carry: result is negative → take the 2's complement of the sum.
a. 1010 − 111
2's complement of 0111: flip→1000 +1 = 1001
1010 + 1001 = 10011 → Carry! Drop it → 11₂ (= 3)
b. 11011 − 1110
2's complement of 01110: flip→10001 +1 = 10010
11011 + 10010 = 101101 → Carry! Drop it → 1101₂ (= 13)
c. 11101 − 11011
2's complement of 11011: flip→00100 +1 = 00101
11101 + 00101 = 100010 → Carry! Drop → 10₂ (= 2)
d. 111 − 1011
2's complement of 1011: flip→0100 +1 = 0101
0111 + 0101 = 1100 → No carry → 2's complement of 1100: flip→0011 +1 = 0100 → −100₂ (= −4)
e. 110 − 1100
2's complement of 1100: flip→0011 +1 = 0100
0110 + 0100 = 1010 → No carry → 2's complement of 1010: flip→0101 +1 = 0110 → −110₂ (= −6)
f. 1001 − 11011
2's complement of 11011: flip→00100 +1 = 00101
01001 + 00101 = 01110 → No carry → 2's complement of 01110: flip→10001 +1 = 10010 → −10010₂ (= −18)
⚡
Short Questions 20–30 — Boolean Algebra & Logic Gates
Definitions, differences, truth tables, laws, De Morgan's theorems, Venn diagrams

Q20. What is Boolean algebra? Differentiate OR gate and AND gate.

Boolean algebra is a branch of mathematics introduced by George Boole in 1854. It deals with variables that have only two possible values: 0 (FALSE) and 1 (TRUE). It provides the algebraic foundation for designing and analysing digital circuits using three basic operations: AND (multiplication), OR (addition), and NOT (complement).

Difference between OR Gate and AND Gate:
  • Symbol: AND uses a D-shaped (flat input) symbol; OR uses a curved (concave input) arrow-like symbol.
  • Boolean expression: AND is written as Y = A · B (multiplication); OR is written as Y = A + B (addition).
  • Output logic: AND outputs 1 only when all inputs are 1; OR outputs 1 when at least one input is 1.
  • Analogy: AND is like switches in series (all must be ON); OR is like switches in parallel (any one ON suffices).
  • Truth table differences:
AND Gate Truth Table
ABY = A·B
000
010
100
111
OR Gate Truth Table
ABY = A+B
000
011
101
111

Q21. What is a Boolean function? Write the Truth Table of Ex-OR gate.

A Boolean function is an algebraic expression formed by combining Boolean variables (A, B, C, …) using the operations AND (·), OR (+), NOT ( ' or overbar ), and parentheses. It maps a set of binary inputs to a single binary output. For example, F(A, B) = A·B + A·B is a Boolean function.

Ex-OR (XOR) Gate Truth Table — Y = A ⊕ B
ABY = A ⊕ B
000
011
101
110

Boolean expression: Y = A ⊕ B = A·B + A·B — outputs 1 when inputs are different.

Q22. What is a logic gate? Explain the NAND gate with Truth Table.

A logic gate is an elementary building block of digital circuits that performs a basic logical operation on one or more binary inputs to produce a single binary output. Each gate implements a specific Boolean function in hardware using transistors.

NAND Gate (NOT-AND)

The NAND gate is the combination of an AND gate followed by a NOT gate. It produces a LOW (0) output only when all inputs are HIGH (1); for all other input combinations, the output is HIGH (1). It is called a universal gate because any Boolean function can be implemented using only NAND gates.

Boolean expression: Y = A · B (read as "A NAND B")

ABA·BY = A·B
0001
0101
1001
1110
  • Gate symbol: AND gate symbol with a small circle (bubble) at the output, indicating inversion.
  • Universal gate: NOT, AND, and OR can all be built from NAND gates alone.
  • Applications: Memory circuits, flip-flops, and combinational logic.

Q23 & Q24. Differentiate between NAND and NOR gates

  • Full form: NAND = NOT + AND; NOR = NOT + OR.
  • Boolean expression: NAND → Y = A · B; NOR → Y = A + B.
  • Gate symbol: NAND = AND symbol with output bubble; NOR = OR symbol with output bubble.
  • Output = 0 when: NAND outputs 0 only when ALL inputs are 1; NOR outputs 0 when ANY input is 1.
  • Output = 1 when: NAND outputs 1 when at least one input is 0; NOR outputs 1 only when ALL inputs are 0.
  • Both are universal gates: Any Boolean function can be implemented using only NAND gates or only NOR gates.
NAND Gate Truth Table
ABY=A·B
001
011
101
110
NOR Gate Truth Table
ABY=A+B
001
010
100
110
Example

If A=0, B=1: NAND output = 0·1 = 0 = 1.   NOR output = 0+1 = 1 = 0.

Q25. Differentiate between XOR gate and XNOR gate

  • Full form: XOR = Exclusive OR; XNOR = Exclusive NOR (or Equivalence gate).
  • Boolean expression: XOR → Y = A⊕B = AB + AB; XNOR → Y = A⊕B = AB + AB.
  • Output = 1 when: XOR outputs 1 when inputs are different; XNOR outputs 1 when inputs are same.
  • Relationship: XNOR is the complement (inverse) of XOR. YXNOR = YXOR.
  • Gate symbol: XNOR uses the XOR symbol with a bubble at the output.
  • Applications: XOR is used in adders, comparators, and parity generators; XNOR is used in equality comparators and parity checkers.
XOR Truth Table
ABY = A⊕B
000
011
101
110
XNOR Truth Table
ABY = A⊕B
001
010
100
111

Q26. What is the duality principle?

Duality Principle

The duality principle states that every valid Boolean equation remains valid if we simultaneously interchange:

  • AND (·) ↔ OR (+)
  • 0 ↔ 1

For example:

  • A + 0 = A  →  dual →  A · 1 = A
  • A + 1 = 1  →  dual →  A · 0 = 0
  • A · (B + C) = A·B + A·C  →  dual →  A + (B·C) = (A+B)·(A+C)

The duality principle reduces the number of theorems we need to prove by half — if a theorem is valid, its dual is automatically valid.

Q27. State and prove the Commutative Law

Commutative Laws

Law 1 (OR): A + B = B + A
Law 2 (AND): A · B = B · A

The order of operands does not affect the result.

Proof for OR (A + B = B + A)
ABA+BB+AEqual?
0000✓
0111✓
1011✓
1111✓
Proof for AND (A · B = B · A)
ABA·BB·AEqual?
0000✓
0100✓
1000✓
1111✓

Since both columns are identical in every case, the commutative laws are proved.

Q28. State and prove the Distributive Law

Distributive Laws

Law 1: A · (B + C) = A·B + A·C   (AND distributes over OR)
Law 2: A + (B · C) = (A+B) · (A+C)   (OR distributes over AND)

Proof of Law 1: A·(B+C) = A·B + A·C
ABCB+CA·(B+C)A·BA·CA·B+A·CEqual?
00000000✓
00110000✓
01010000✓
01110000✓
10000000✓
10111011✓
11011101✓
11111111✓

Since columns 5 and 8 are identical for every combination, A·(B+C) = A·B + A·C is proved. Law 2 follows by the duality principle.

Q29. State and prove De Morgan's Theorems

De Morgan's Theorems

Theorem 1: A + B = A · B
"The complement of a sum equals the product of the complements."

Theorem 2: A · B = A + B
"The complement of a product equals the sum of the complements."

Proof of Theorem 1: A+B = A·B
ABA+BA+BABA·B
0001111
0110100
1010010
1110000

Columns 4 and 7 are identical → Theorem 1 is proved. ✓

Proof of Theorem 2: A·B = A+B
ABA·BA·BABA+B
0001111
0101101
1001011
1110000

Columns 4 and 7 are identical → Theorem 2 is proved. ✓

Q30. Draw the Venn diagram of AND, OR, and NOT gates

A Venn diagram visually represents the logical operation using overlapping circles (sets). The shaded region indicates where the output is 1 (TRUE).

A ∩ B
(overlap only)
AND Gate
Output = 1 only in the intersection (A ∩ B) — where both A and B are TRUE.
A ∪ B
(all shaded)
OR Gate
Output = 1 in the union (A ∪ B) — wherever A, B, or both are TRUE.
A̅
(outside A)
NOT Gate
Output = 1 in the complement of A (A̅) — the area outside circle A.
📖
Long Answer Questions 1–3
Comprehensive descriptions of Boolean algebra and logic gates with symbols & truth tables

Long Q1. What is Boolean algebra? Describe AND, OR, NOT, and NAND gates.

Boolean algebra is a mathematical system for analysing and simplifying logical expressions, developed by George Boole in 1854. It operates on variables that take only two values — 0 (FALSE/LOW) and 1 (TRUE/HIGH) — and uses three fundamental operations: AND (conjunction), OR (disjunction), and NOT (negation).

Boolean algebra is the theoretical foundation of all digital electronics: it is used to design, analyse, and simplify logic circuits in computers, calculators, and virtually every digital device.

1. AND Gate
  • Function: Produces 1 only when all inputs are 1.
  • Symbol: D-shaped body with a flat input side and a curved output side.
  • Expression: Y = A · B (also written Y = AB)
  • Analogy: Two switches in series — both must be ON for current to flow.
ABY = A·B
000
010
100
111
2. OR Gate
  • Function: Produces 1 when at least one input is 1.
  • Symbol: Curved (concave) input side with a pointed output — resembling an arrow.
  • Expression: Y = A + B
  • Analogy: Two switches in parallel — current flows if either (or both) is ON.
ABY = A+B
000
011
101
111
3. NOT Gate (Inverter)
  • Function: Produces the complement (opposite) of the input.
  • Symbol: A triangle pointing right with a small circle (bubble) at the output.
  • Expression: Y = A (also written Y = A' or Y = ¬A)
  • Single-input gate: The only basic gate with just one input.
AY = A
01
10
4. NAND Gate (NOT-AND)
  • Function: Complement of AND — produces 0 only when all inputs are 1.
  • Symbol: AND gate symbol with a bubble at the output.
  • Expression: Y = A · B
  • Universal gate: All other gates (AND, OR, NOT) can be built using NAND gates alone.
ABY = A·B
001
011
101
110

Long Q2. What is a logic gate? Describe any four logic gates.

A logic gate is an electronic circuit that performs a fundamental logical operation on one or more binary inputs to produce a single binary output. Logic gates are the basic building blocks of all digital systems — from simple calculators to complex microprocessors. They are implemented using transistors and are governed by the rules of Boolean algebra.

Types of Logic Gates
  • Basic gates: AND, OR, NOT
  • Universal gates: NAND, NOR
  • Special-purpose gates: XOR (Exclusive OR), XNOR (Exclusive NOR)
Gate 1 — AND Gate
  • Inputs: Two or more   |   Expression: Y = A · B
  • Logic: Output HIGH only when all inputs HIGH.
  • Symbol: D-shaped (flat input, curved output).
ABY
000
010
100
111
Gate 2 — OR Gate
  • Inputs: Two or more   |   Expression: Y = A + B
  • Logic: Output HIGH when at least one input HIGH.
  • Symbol: Curved input side, pointed output.
ABY
000
011
101
111
Gate 3 — NOT Gate (Inverter)
  • Input: One   |   Expression: Y = A
  • Logic: Inverts the input (0→1, 1→0).
  • Symbol: Triangle + output bubble.
AY
01
10
Gate 4 — XOR Gate (Exclusive OR)
  • Inputs: Two   |   Expression: Y = A ⊕ B = AB + AB
  • Logic: Output HIGH when inputs are different.
  • Symbol: OR gate with an extra curved line on the input side.
  • Applications: Binary adders (half adder, full adder), parity generators/checkers.
ABY
000
011
101
110

Long Q3. Describe any five logic gates with Truth Table and gate symbol.

Below are five important logic gates with complete descriptions, Boolean expressions, symbols, and truth tables.

1. AND Gate
  • Symbol: D-shaped (flat left, curved right).
  • Expression: Y = A · B
  • Logic: 1 only when ALL inputs = 1.
ABY
000
010
100
111
2. OR Gate
  • Symbol: Curved (concave) input, pointed output.
  • Expression: Y = A + B
  • Logic: 1 when ANY or ALL inputs = 1.
ABY
000
011
101
111
3. NOT Gate
  • Symbol: Triangle with output bubble.
  • Expression: Y = A
  • Logic: Inverts the single input.
AY
01
10
4. NAND Gate
  • Symbol: AND gate + output bubble.
  • Expression: Y = A · B
  • Logic: 0 only when ALL inputs = 1; otherwise 1. Universal gate.
ABY
001
011
101
110
5. NOR Gate
  • Symbol: OR gate + output bubble.
  • Expression: Y = A + B
  • Logic: 1 only when ALL inputs = 0; otherwise 0. Universal gate.
ABY
001
010
100
110
Summary Table of All Seven Logic Gates
GateExpressionOutput 1 whenType
ANDY = A·BAll inputs = 1Basic
ORY = A+BAny input = 1Basic
NOTY = AInput = 0Basic
NANDY = A·BNot all inputs = 1Universal
NORY = A+BAll inputs = 0Universal
XORY = A⊕BInputs differSpecial
XNORY = A⊕BInputs sameSpecial

Frequently asked questions

What is Number System & Ttheir conversion and Boolean Logic about?

This chapter covers the fundamental concepts of number systems, including their conversion between binary, octal, decimal, and hexadecimal. It also delves into Boolean algebra, logic gates, and their operations, providing a comprehensive understanding of digital logic.

Which topics are covered in Number System & Ttheir conversion and Boolean Logic?

Class 11 Computer Science “Number System & Ttheir conversion and Boolean Logic” covers: Positional Number Systems; Base Conversions (Binary, Octal, Decimal, Hexadecimal); Binary Arithmetic (Addition, Subtraction); Complement Methods (1's and 2's Complement); Boolean Algebra; Logic Gates (AND, OR, NOT, NAND, NOR, XOR, XNOR); De Morgan's Theorems; Boolean Function and Truth Tables.

What should I focus on in Number System & Ttheir conversion and Boolean Logic for the exam?

Students should focus on understanding number system conversions, performing binary arithmetic, and applying Boolean algebra principles to logic gates and their operations, including De Morgan's theorems.

What are the key formulas or definitions in Number System & Ttheir conversion and Boolean Logic?

Base-n to Decimal: Sum of (digit × base^position); Decimal to Base-n: Repeated division/multiplication; Binary to Octal: Group bits in threes; Binary to Hexadecimal: Group bits in fours; Boolean Algebra Laws (Commutative, Distributive, Duality, De Morgan's).

Where can I read the Class 11 Computer Science “Number System & Ttheir conversion and Boolean Logic” solutions?

Right on this page. They are free and you do not need to sign up. For chapter quizzes and the AI tutor, install the Sikshya Plus app.

Study tips

Free for Class 9 to 12

Do not just read it. Practice it.

You have read the solutions for Number System & Ttheir conversion and Boolean Logic. Now test yourself, ask the AI tutor and keep your streak going.

Sikshya Plus chapter quiz screen with class, subject and difficulty options
Sikshya AI personal tutor chat inside the app
Sikshya Plus AI tools screen: question assistant, summarizer, translator, grammar checker
Chapter list with Past Q, materials, posts and books tabs
  • AI quizzes for this chapterTest yourself with instant feedback and explanations after every answer.
  • AI tutor, free, 24/7Stuck on a question? Ask in your own words and get a step-by-step explanation.
  • 14 AI tools in one appSummarizer, grammar checker, flashcards, essay help, math solver and more.
  • Past questions and notesPast papers and your own notes organized chapter by chapter.
Download free on Google Play Scan with your phone to install