1 · The Hook
🎣
A light switch is either off or on. A computer is built from billions of tiny electronic switches, so everything it stores (numbers, text, photos) must be written using only two symbols: 0 and 1. Before any gate, adder or flip-flop, we need to be fluent in this two-symbol way of counting. GATE asks base conversions directly, and every later topic uses them.
2 · Predict First
🤔
In our usual numbers, 345 means 3 hundreds + 4 tens + 5 ones. In binary, the places are worth 8, 4, 2 and 1. What number does 1011₂ stand for?
Make a guess in your head. The answer opens Section 3.
3 · Core Concept
💡
Predict First — the answer
1 × 8 + 0 × 4 + 1 × 2 + 1 × 1 = 11.
🗣️
In plain words
"Digital" means a signal is read as one of a few fixed values, here just two: low voltage = 0, high voltage = 1. One such 0/1 is a bit. To write bigger numbers we line bits up, exactly like digits in an ordinary number, except that each place is worth twice the place to its right instead of ten times.
1. Why two values?
A wire's voltage wobbles a little because of electrical noise. If the circuit only needs to tell "clearly low" from "clearly high", small wobbles don't matter. That makes two-valued (binary) circuits cheap and reliable.
2. Place value
In decimal (base 10), places are worth 1, 10, 100, 1000, … (powers of 10). In binary (base 2), places are worth powers of 2:
| Place (from the right) | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
|---|---|---|---|---|---|---|---|---|
| Worth | 2⁷ = 128 | 64 | 32 | 16 | 8 | 4 | 2 | 1 |
Learn the powers of two up to 2¹⁰ = 1024 by heart: 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024.
3. Binary → decimal
Add the worths of the places that hold a 1. 11010₂ = 16 + 8 + 2 = 26.
4. Decimal → binary (repeated division)
Divide by 2 again and again, writing down the remainders; stop at 0. Read the remainders from the last one up to the first. 45 ÷ 2 = 22 r 1, 22 ÷ 2 = 11 r 0, 11 ÷ 2 = 5 r 1, 5 ÷ 2 = 2 r 1, 2 ÷ 2 = 1 r 0, 1 ÷ 2 = 0 r 1 → read upward: 101101₂. Quick check by the other method: 45 = 32 + 8 + 4 + 1 → places 5, 3, 2, 0 are 1 → 101101 ✓.
5. Names
- LSB (least significant bit): the rightmost bit, worth 1. MSB (most significant bit): the leftmost.
- Nibble = 4 bits, byte = 8 bits.
- With n bits there are 2ⁿ different patterns; read as plain (unsigned) numbers they cover 0 to 2ⁿ − 1.
- To write a number N you need ⌈log₂(N + 1)⌉ bits (the smallest n with 2ⁿ > N). 1000 needs 10 bits because 2⁹ = 512 ≤ 1000 < 1024 = 2¹⁰.
4 · Visual
45 to binary by repeated division
45 / 2 = 22 remainder 1 <- LSB (read last)
22 / 2 = 11 remainder 0
11 / 2 = 5 remainder 1
5 / 2 = 2 remainder 1
2 / 2 = 1 remainder 0
1 / 2 = 0 remainder 1 <- MSB (read first)
read upward: 1 0 1 1 0 1 = 32 + 8 + 4 + 1 = 45
5 · Worked Examples
Example 1 Easy
Convert 11010₂ to decimal.
Solution
16 + 8 + 2 = 26.
Example 2 Medium
Convert 45 to binary.
Solution
Remainders 1, 0, 1, 1, 0, 1 read upward: 101101₂.
Example 3 GATE
What is the smallest number of bits needed to write the number 1000 in unsigned binary?
Solution
2⁹ = 512 is too small, 2¹⁰ = 1024 > 1000 → 10 bits.
6 · GATE Traps
⚠️
- Read division remainders from the bottom up (the last remainder is the MSB).
- n bits give 2ⁿ patterns, but the largest unsigned value is 2ⁿ − 1 (because 0 is one of them).
- Leading zeros change nothing: 0101₂ = 101₂ = 5.
- To hold N you need ⌈log₂(N + 1)⌉ bits, not ⌈log₂ N⌉ (think of N = 8: it needs 4 bits).
7 · Memory Hook
🧠
"Binary places double: 1, 2, 4, 8 … Divide by 2, read the remainders upward."
8 · Connect the Dots
Binary strings get long quickly. The next lesson introduces octal and hexadecimal, short-hands that group bits, and shows how to move between any two bases, fractions included.
9 · Self-Test
GATE format. Try every question before opening the vault.
Q1NAT1 markBinary to decimal
What is 110101₂ in decimal?
Numerical answer: ________
Q2MCQ1 markDecimal to binary
What is 100 in binary?
- (A) 1001100
- (B) 1100010
- (C) 1100100
- (D) 1010100
Q3NAT1 markBits needed
What is the smallest number of bits that can hold the unsigned number 300?
Numerical answer: ________
Q4NAT1 markRange
What is the largest unsigned number that fits in 6 bits?
Numerical answer: ________
Q5MCQ1 markNames
In the 8-bit pattern 10010110, the MSB is:
- (A) the rightmost bit, 0
- (B) the middle bit
- (C) the number of 1s, 4
- (D) the leftmost bit, 1
10 · Rule Card
- Binary places are powers of 2: 1, 2, 4, 8, 16, …; value = sum of the places holding 1.
- Decimal → binary: divide by 2 repeatedly, read remainders bottom-up.
- n bits: 2ⁿ patterns; unsigned range 0 … 2ⁿ − 1; N needs ⌈log₂(N + 1)⌉ bits.
- LSB rightmost, MSB leftmost; nibble 4 bits, byte 8 bits.
11 · Concept Ledger
Unlocked in this lesson. From here on, these terms may be used.
digital signalbitbinary (base 2)place valuepowers of twobinary to decimaldecimal to binary by repeated divisionLSB and MSBnibblebyte2ⁿ patternsbits needed for a number
12 · Answer Vault
Answer Vault
Try the questions first. Open when you are ready to check.
Self-Test
Q1 Answer: 531 mark
32 + 16 + 4 + 1.
Re-read: Lesson 0.1.1 — What "digital" means: bits, binary numbers and place value
Q2 Answer: (C)1 mark
100 = 64 + 32 + 4.
- (A) is wrong: That is 76.
- (B) is wrong: That is 98.
- (D) is wrong: That is 84.
Re-read: Lesson 0.1.1 — What "digital" means: bits, binary numbers and place value
Q3 Answer: 91 mark
2⁸ = 256 ≤ 300 < 512 = 2⁹.
Re-read: Lesson 0.1.1 — What "digital" means: bits, binary numbers and place value
Q4 Answer: 631 mark
2⁶ − 1.
Re-read: Lesson 0.1.1 — What "digital" means: bits, binary numbers and place value
Q5 Answer: (D)1 mark
Most significant = leftmost, worth 2⁷.
- (A) is wrong: That is the LSB.
- (B) is wrong: No.
- (C) is wrong: Not a bit position.
Re-read: Lesson 0.1.1 — What "digital" means: bits, binary numbers and place value