Binary ↔ Decimal, Octal and Hexadecimal Conversions – Grade 10 ICT Notes 3.3

© 2026 schoolict.net (Ruwan Mangala Suraweera)

3.3 Binary ↔ Decimal, Octal and Hexadecimal ConversionsBinary ↔ දශම, Octal සහ Hexadecimal හැරවීම්

G.C.E. O/L Grade 10 ICT · Lesson 3G.C.E. O/L ICT · 10 ශ්‍රේණිය · පාඩම 3

Prints all tabs in the language you are reading. Use “Save as PDF” in the print window to keep a copy.ඔබ කියවන භාෂාවෙන් සියලු tabs මුද්‍රණය වේ. පිටපතක් තියාගන්න print window එකේ “Save as PDF” තෝරන්න.
🎬Video coming soon in this language. Switch language to watch the other video.මේ භාෂාවෙන් වීඩියෝව ඉක්මනින් එනවා. අනෙක් වීඩියෝව බලන්න භාෂාව මාරු කරන්න.

In this videoමේ වීඩියෝවේ

  • Binary → decimal: add place values of the 1s.Binary → දශම: 1 ඇති ස්ථානවල අගය එකතු කරන්න.
  • Binary → octal: groups of 3 from the right.Binary → octal: දකුණේ සිට 3 බැගින්.
  • Binary → hex: groups of 4 from the right.Binary → hex: දකුණේ සිට 4 බැගින්.
  • Add leading 0s to complete the last group.අවසාන කාණ්ඩයට වමට 0 එකතු කරන්න.
  • Octal ↔ hex: go through binary.Octal ↔ hex: binary හරහා යන්න.
3 bits4 bitsNibbleLeading 0Group rightVia binaryCheck

Notesසටහන්

Now we go the other way. You will convert binary to decimal using place values, and convert binary ↔ octal and binary ↔ hexadecimal quickly by grouping bits in 3s and 4s. Finally you will convert octal ↔ hexadecimal through binary. Only positive whole numbers are used.දැන් අපි අනෙක් පැත්තට යමු. ස්ථානීය අගය භාවිතයෙන් binary → දශම ද, bit 3 සහ 4 කාණ්ඩ කිරීමෙන් binary ↔ octal සහ binary ↔ hexadecimal ද ඉක්මනින් හරවමු. අවසානයේ binary හරහා octal ↔ hexadecimal හරවමු. ධන පූර්ණ සංඛ්‍යා පමණක් භාවිතා වේ.

1. Binary → decimal (place value method)1. Binary → දශම (ස්ථානීය අගය ක්‍රමය)

Write the place values (1, 2, 4, 8 …) under each bit from the right. Add the place values where the bit is 1.දකුණේ සිට සෑම bit එකකටම යටින් ස්ථානීය අගය (1, 2, 4, 8 …) ලියන්න. Bit එක 1 වන ස්ථානවල අගයන් එකතු කරන්න.

Worked example 1: 101101₂ → decimalඋදාහරණය 1: 101101₂ → දශම

Digitඉලක්කම110011110011
Place valueස්ථානීය අගය2⁵ = 322⁵ = 322⁴ = 162⁴ = 162³ = 82³ = 82² = 42² = 42¹ = 22¹ = 22⁰ = 12⁰ = 1
Digit × place valueඉලක්කම × ස්ථානීය අගය1 × 32 = 321 × 32 = 320 × 16 = 00 × 16 = 01 × 8 = 81 × 8 = 81 × 4 = 41 × 4 = 40 × 2 = 00 × 2 = 01 × 1 = 11 × 1 = 1
💡 32 + 0 + 8 + 4 + 0 + 1 = 45₁₀32 + 0 + 8 + 4 + 0 + 1 = 45₁₀

The same method works for octal and hex → decimal: multiply each digit by its place value and add.Octal සහ hex → දශම සඳහාද එම ක්‍රමයමයි: සෑම ඉලක්කමක්ම ස්ථානීය අගයෙන් ගුණ කර එකතු කරන්න.

Worked example 2: 3A7₁₆ → decimalඋදාහරණය 2: 3A7₁₆ → දශම

Digitඉලක්කම33AA77
Place valueස්ථානීය අගය16² = 25616² = 25616¹ = 1616¹ = 1616⁰ = 116⁰ = 1
Digit × place valueඉලක්කම × ස්ථානීය අගය3 × 256 = 7683 × 256 = 76810 × 16 = 16010 × 16 = 1607 × 1 = 77 × 1 = 7
💡 768 + 160 + 7 = 935₁₀768 + 160 + 7 = 935₁₀

2. Binary ↔ octal (groups of 3)2. Binary ↔ octal (bit 3 කාණ්ඩ)

Because 8 = 2³, one octal digit = exactly 3 bits. Group the bits in threes from the right; add 0s on the left if needed. Change each group to one digit.8 = 2³ නිසා octal ඉලක්කම් 1 = bit 3 හරියටම. Bits දකුණේ සිට තුන බැගින් කාණ්ඩ කරන්න; අවශ්‍ය නම් වමට 0 එකතු කරන්න. සෑම කාණ්ඩයක්ම එක් ඉලක්කමකට හරවන්න.

OctalOctal0011223344556677
BinaryBinary000000001001010010011011100100101101110110111111

Worked example 3: 1101011₂ → octalඋදාහරණය 3: 1101011₂ → octal

Groupකාණ්ඩය001001101101011011
Valueඅගය115533
💡 1101011₂ = 153₈ (two 0s were added on the left to make 001).1101011₂ = 153₈ (001 සෑදීමට වමට 0 දෙකක් එකතු කළා).

Worked example 4: 572₈ → binaryඋදාහරණය 4: 572₈ → binary

Digitඉලක්කම557722
Bitsබිටු101101111111010010
💡 572₈ = 101111010₂572₈ = 101111010₂

3. Binary ↔ hexadecimal (groups of 4)3. Binary ↔ hexadecimal (bit 4 කාණ්ඩ)

Because 16 = 2⁴, one hex digit = exactly 4 bits (a nibble). Group from the right in fours.16 = 2⁴ නිසා hex ඉලක්කම් 1 = bit 4 හරියටම (nibble). දකුණේ සිට හතර බැගින් කාණ්ඩ කරන්න.

HexHex00112233445566778899AABBCCDDEEFF
BinaryBinary00000000000100010010001000110011010001000101010101100110011101111000100010011001101010101011101111001100110111011110111011111111

Worked example 5: 1011111010₂ → hexadecimalඋදාහරණය 5: 1011111010₂ → hexadecimal

Groupකාණ්ඩය001000101111111110101010
Valueඅගය22FFAA
💡 1011111010₂ = 2FA₁₆1011111010₂ = 2FA₁₆

Worked example 6: 9C₁₆ → binaryඋදාහරණය 6: 9C₁₆ → binary

Digitඉලක්කම99CC
Bitsබිටු1001100111001100
💡 9C₁₆ = 10011100₂9C₁₆ = 10011100₂

4. Octal ↔ hexadecimal (via binary)4. Octal ↔ hexadecimal (binary හරහා)

There is no direct grouping between 8 and 16. Go through binary: octal → binary (3 bits each) → regroup in 4s → hex, and the reverse for hex → octal.8 සහ 16 අතර සෘජු කාණ්ඩ කිරීමක් නැත. Binary හරහා යන්න: octal → binary (බැගින් bit 3) → 4 බැගින් නැවත කාණ්ඩ → hex; hex → octal සඳහා ප්‍රතිවිරුද්ධව.

Worked example 7: 357₈ → hexadecimalඋදාහරණය 7: 357₈ → hexadecimal

Digitඉලක්කම335577
Bitsබිටු011011101101111111
Groupකාණ්ඩය1110111011111111
ValueඅගයEEFF
💡 357₈ = 11101111₂ = EF₁₆ (check: both equal 239₁₀).357₈ = 11101111₂ = EF₁₆ (පරීක්ෂාව: දෙකම 239₁₀).

Worked example 8: 2B₁₆ → octalඋදාහරණය 8: 2B₁₆ → octal

Digitඉලක්කම22BB
Bitsබිටු0010001010111011
Groupකාණ්ඩය101101011011
Valueඅගය5533
💡 2B₁₆ = 101011₂ = 53₈2B₁₆ = 101011₂ = 53₈
💡 Common mistakes: grouping from the LEFT instead of the right; forgetting leading 0s; writing 10 instead of A in hex.පොදු වැරදි: දකුණ වෙනුවට වමේ සිට කාණ්ඩ කිරීම; ඉදිරි 0 අමතක කිරීම; hex හි A වෙනුවට 10 ලිවීම.

Key Wordsප්‍රධාන පද

Groupingකාණ්ඩ කිරීම
Splitting a binary number into groups of 3 or 4 bits from the right.Binary අංකයක් දකුණේ සිට bit 3 හෝ 4 කාණ්ඩවලට බෙදීම.
NibbleNibble
A group of 4 bits = one hexadecimal digit.bit 4 ක කාණ්ඩය = hex ඉලක්කම් එකක්.
TriadTriad (bit 3 කාණ්ඩය)
A group of 3 bits = one octal digit.bit 3 ක කාණ්ඩය = octal ඉලක්කම් එකක්.
Leading zeroඉදිරි ශුන්‍යය
A 0 added on the left to complete a group; it does not change the value.කාණ්ඩයක් සම්පූර්ණ කිරීමට වමට එක් කරන 0; අගය වෙනස් නොවේ.
Place value methodස්ථානීය අගය ක්‍රමය
Multiply each digit by its place value and add to get decimal.දශම ලබාගැනීමට සෑම ඉලක්කමක්ම ස්ථානීය අගයෙන් ගුණ කර එකතු කිරීම.
Binary to decimalBinary සිට දශම
Add the place values where the bit is 1.Bit 1 වන ස්ථානවල අගයන් එකතු කිරීම.
Binary to octalBinary සිට octal
Group bits in 3s from the right and convert each group.Bits දකුණේ සිට 3 බැගින් කාණ්ඩ කර හැරවීම.
Binary to hexadecimalBinary සිට hexadecimal
Group bits in 4s from the right and convert each group.Bits දකුණේ සිට 4 බැගින් කාණ්ඩ කර හැරවීම.
Octal to binaryOctal සිට binary
Write each octal digit as 3 bits.සෑම octal ඉලක්කමක්ම bit 3 ලෙස ලිවීම.
Hexadecimal to binaryHexadecimal සිට binary
Write each hex digit as 4 bits.සෑම hex ඉලක්කමක්ම bit 4 ලෙස ලිවීම.
Octal to hexadecimalOctal සිට hexadecimal
Convert octal to binary, then regroup in 4s.Octal → binary, පසුව 4 බැගින් නැවත කාණ්ඩ කිරීම.
Positive integerධන නිඛිලය
A whole number greater than zero (no fractions, no minus sign).බිංදුවට වැඩි පූර්ණ සංඛ්‍යාවක් (භාග නැත, ඍණ නැත).

Sample Q&Aආදර්ශ ප්‍රශ්න සහ පිළිතුරු

1Convert 11010₂ to decimal.11010₂ දශම වලට හරවන්න.

Answerපිළිතුර: 16 + 8 + 2 = 26₁₀.16 + 8 + 2 = 26₁₀.

2Why do we group bits in 3s for octal?Octal සඳහා bits 3 බැගින් කාණ්ඩ කරන්නේ ඇයි?

Answerපිළිතුර: Because 8 = 2³, so each octal digit is exactly 3 bits.8 = 2³ නිසා සෑම octal ඉලක්කමක්ම හරියටම bit 3 කි.

3Convert 11110110₂ to hexadecimal.11110110₂ hexadecimal වලට හරවන්න.

Answerපිළිතුර: 1111 | 0110 → F | 6 → F6₁₆.1111 | 0110 → F | 6 → F6₁₆.

4Convert 47₈ to binary.47₈ binary වලට හරවන්න.

Answerපිළිතුර: 4 → 100, 7 → 111 → 100111₂.4 → 100, 7 → 111 → 100111₂.

5From which side do you start grouping bits?Bits කාණ්ඩ කිරීම ආරම්භ කරන්නේ කුමන පැත්තෙන්ද?

Answerපිළිතුර: From the right (the LSB). Add leading 0s on the left if the last group is short.දකුණෙන් (LSB). අවසාන කාණ්ඩය අඩු නම් වමට 0 එකතු කරන්න.

6How do you convert octal to hexadecimal?Octal → hexadecimal හරවන්නේ කෙසේද?

Answerපිළිතුර: Change each octal digit to 3 bits, then regroup the bits in 4s from the right and change each group to a hex digit.සෑම octal ඉලක්කමක්ම bit 3 කර, දකුණේ සිට 4 බැගින් නැවත කාණ්ඩ කර hex ඉලක්කම් කරන්න.

MCQබහුවරණ ප්‍රශ්න

Choose the correct answer for each question.සෑම ප්‍රශ්නයකටම නිවැරදි පිළිතුර තෝරන්න.

Scoreලකුණු: 0 / 15

1What is 101101₂ in decimal?101101₂ දශම වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: A

32+8+4+1 = 45.32+8+4+1 = 45.

2What is 1111₂ in decimal?1111₂ දශම වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: C

8+4+2+1 = 15.8+4+2+1 = 15.

3What is 1100100₂ in decimal?1100100₂ දශම වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: A

64+32+4 = 100.64+32+4 = 100.

4What is 1101011₂ in octal?1101011₂ octal වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: B

001 101 011 → 1 5 3.001 101 011 → 1 5 3.

5What is 1011111010₂ in hexadecimal?1011111010₂ hexadecimal වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: C

0010 1111 1010 → 2 F A.0010 1111 1010 → 2 F A.

6What is 572₈ in binary?572₈ binary වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: D

5→101, 7→111, 2→010.5→101, 7→111, 2→010.

7What is 9C₁₆ in binary?9C₁₆ binary වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: C

9→1001, C→1100.9→1001, C→1100.

8When converting binary to hexadecimal, bits are grouped in:Binary → hexadecimal හැරවීමේදී bits කාණ්ඩ කරන්නේ:

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: D

16 = 2⁴; start at the LSB.16 = 2⁴; LSB වලින් පටන් ගන්න.

9What is 357₈ in hexadecimal?357₈ hexadecimal වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: B

357₈ = 11101111₂ = EF₁₆.357₈ = 11101111₂ = EF₁₆.

10What is 2B₁₆ in octal?2B₁₆ octal වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: A

2B = 101011₂ = 101 011 = 53₈.2B = 101011₂ = 101 011 = 53₈.

11What is 3A7₁₆ in decimal?3A7₁₆ දශම වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: B

3×256 + 10×16 + 7 = 935.3×256 + 10×16 + 7 = 935.

12What is 11110110₂ in hexadecimal?11110110₂ hexadecimal වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: C

1111 0110 → F6.1111 0110 → F6.

13One hexadecimal digit is equal to how many bits?Hexadecimal ඉලක්කම් එකක් bits කීයකට සමානද?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: A

16 = 2⁴ → 4 bits.16 = 2⁴ → bit 4.

14What is 75₈ in decimal?75₈ දශම වලින්?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: D

7×8 + 5 = 61.7×8 + 5 = 61.

15Which binary number equals 7F₁₆?7F₁₆ ට සමාන binary අංකය?

✔ Correct!නිවැරදියි!✘ Not quite.වැරදියි. Correct answerනිවැරදි පිළිතුර: B

7→0111, F→1111 → 1111111.7→0111, F→1111 → 1111111.

MCQ answer keyMCQ පිළිතුරු

  1. A – 32+8+4+1 = 45.32+8+4+1 = 45.
  2. C – 8+4+2+1 = 15.8+4+2+1 = 15.
  3. A – 64+32+4 = 100.64+32+4 = 100.
  4. B – 001 101 011 → 1 5 3.001 101 011 → 1 5 3.
  5. C – 0010 1111 1010 → 2 F A.0010 1111 1010 → 2 F A.
  6. D – 5→101, 7→111, 2→010.5→101, 7→111, 2→010.
  7. C – 9→1001, C→1100.9→1001, C→1100.
  8. D – 16 = 2⁴; start at the LSB.16 = 2⁴; LSB වලින් පටන් ගන්න.
  9. B – 357₈ = 11101111₂ = EF₁₆.357₈ = 11101111₂ = EF₁₆.
  10. A – 2B = 101011₂ = 101 011 = 53₈.2B = 101011₂ = 101 011 = 53₈.
  11. B – 3×256 + 10×16 + 7 = 935.3×256 + 10×16 + 7 = 935.
  12. C – 1111 0110 → F6.1111 0110 → F6.
  13. A – 16 = 2⁴ → 4 bits.16 = 2⁴ → bit 4.
  14. D – 7×8 + 5 = 61.7×8 + 5 = 61.
  15. B – 7→0111, F→1111 → 1111111.7→0111, F→1111 → 1111111.

Structured Questionsව්‍යුහගත ප්‍රශ්න

1Convert 10110011₂ to (i) decimal (ii) octal (iii) hexadecimal. Show working. (6 marks)10110011₂ (i) දශම (ii) octal (iii) hexadecimal වලට හරවන්න. ක්‍රියාවලිය පෙන්වන්න. (ලකුණු 6) (6 marksලකුණු 6)

Show model answerආදර්ශ පිළිතුර පෙන්වන්න
(i) 128+32+16+2+1 = 179₁₀
(ii) 010 110 011 → 263₈
(iii) 1011 0011 → B3₁₆
(i) 128+32+16+2+1 = 179₁₀
(ii) 010 110 011 → 263₈
(iii) 1011 0011 → B3₁₆

2Convert 645₈ to binary and then to hexadecimal. (4 marks)645₈ binary වලට, පසුව hexadecimal වලට හරවන්න. (ලකුණු 4) (4 marksලකුණු 4)

Show model answerආදර්ශ පිළිතුර පෙන්වන්න
6→110, 4→100, 5→101 → 110100101₂. Regroup: 0001 1010 0101 → 1A5₁₆.6→110, 4→100, 5→101 → 110100101₂. නැවත කාණ්ඩ: 0001 1010 0101 → 1A5₁₆.

3Convert A5₁₆ to (i) binary (ii) octal (iii) decimal. (3 marks)A5₁₆ (i) binary (ii) octal (iii) දශම වලට හරවන්න. (ලකුණු 3) (3 marksලකුණු 3)

Show model answerආදර්ශ පිළිතුර පෙන්වන්න
(i) 1010 0101 → 10100101₂ (ii) 010 100 101 → 245₈ (iii) 10×16+5 = 165₁₀(i) 1010 0101 → 10100101₂ (ii) 010 100 101 → 245₈ (iii) 10×16+5 = 165₁₀

4A student converted 1101101₂ to hex as 1101 101 → D5. (i) What mistake was made? (1 mark) (ii) Give the correct answer. (2 marks)සිසුවෙක් 1101101₂ hex වලට 1101 101 → D5 ලෙස හැරෙව්වා. (i) කළ වරද කුමක්ද? (ලකුණු 1) (ii) නිවැරදි පිළිතුර දෙන්න. (ලකුණු 2) (3 marksලකුණු 3)

Show model answerආදර්ශ පිළිතුර පෙන්වන්න
(i) Grouped from the left instead of the right. (ii) 0110 1101 → 6D₁₆.(i) දකුණ වෙනුවට වමේ සිට කාණ්ඩ කළා. (ii) 0110 1101 → 6D₁₆.

5Arrange in ascending order after converting to decimal: 1110₂, 17₈, 10₁₆. (3 marks)දශම වලට හරවා ආරෝහණ පිළිවෙළට සකසන්න: 1110₂, 17₈, 10₁₆. (ලකුණු 3) (3 marksලකුණු 3)

Show model answerආදර්ශ පිළිතුර පෙන්වන්න
1110₂ = 14, 17₈ = 15, 10₁₆ = 16 → 1110₂, 17₈, 10₁₆.1110₂ = 14, 17₈ = 15, 10₁₆ = 16 → 1110₂, 17₈, 10₁₆.

6Convert 1F₁₆ to octal using binary. Show both steps. (3 marks)Binary හරහා 1F₁₆ octal වලට හරවන්න. පියවර දෙකම පෙන්වන්න. (ලකුණු 3) (3 marksලකුණු 3)

Show model answerආදර්ශ පිළිතුර පෙන්වන්න
1→0001, F→1111 → 11111₂. Regroup in 3s: 011 111 → 37₈.1→0001, F→1111 → 11111₂. 3 බැගින්: 011 111 → 37₈.

🎮 Game🎮 ක්‍රීඩා

Pick a game. Each one uses words from this lesson.ක්‍රීඩාවක් තෝරන්න. හැම එකක්ම මේ පාඩමේ වචන පාවිච්චි කරනවා.

Summary & Downloadsසාරාංශය සහ බාගත කිරීම්

Key pointsප්‍රධාන කරුණු

  • Binary → decimal: add place values where the bit is 1.Binary → දශම: bit 1 වන ස්ථානවල අගයන් එකතු කරන්න.
  • Octal/hex → decimal: digit × place value, then add.Octal/hex → දශම: ඉලක්කම × ස්ථානීය අගය, පසුව එකතු කරන්න.
  • 1 octal digit = 3 bits (8 = 2³).Octal ඉලක්කම් 1 = bit 3 (8 = 2³).
  • 1 hex digit = 4 bits (16 = 2⁴), called a nibble.Hex ඉලක්කම් 1 = bit 4 (16 = 2⁴), nibble.
  • Always group from the right; add leading 0s on the left.හැම විටම දකුණේ සිට කාණ්ඩ කරන්න; වමට 0 එකතු කරන්න.
  • Octal/hex → binary: write each digit as 3 or 4 bits.Octal/hex → binary: සෑම ඉලක්කමක්ම bit 3 හෝ 4 ලෙස.
  • Octal ↔ hex: go through binary and regroup.Octal ↔ hex: binary හරහා ගොස් නැවත කාණ්ඩ කරන්න.
  • Check answers by converting both to decimal.දෙකම දශම වලට හරවා පිළිතුරු පරීක්ෂා කරන්න.

Downloadsබාගත කිරීම්

Full Lesson 3 PDFසම්පූර්ණ පාඩම 3 PDF: English · සිංහල

Next noteඊළඟ සටහන 3.4 →

© 2026 schoolict.net (Ruwan Mangala Suraweera). All rights reserved.සියලු හිමිකම් ඇවිරිණි.