Computing Fundamentals
1
Number System
Week002 – Number System
Laboratory Exercise 001- Practice Laboratory 001
1. Convert 11011101(binary) to base 10, 8 and 16
Base 10:
1 1 0 1 1 1 0 1 1
(2*7)+1(2*6)+0(2*5)+1(2*4)+1(2*3)+1(2*2)+0(2*1)+1(2*0)
=128+64+0+16+8+4+0+1 =221
Base 8:
221/8=27 with remainder 5
27/8=3 with remainder 3
3/8= 0 with remainder 3
=335
Base 16:
221/16 = 13
with remainder 13 (D)
13/16 = 0
with remainder 13 (D)
= DD
Assessments
2. Convert 25(decimal) to base 2, 8 and 16
Base 2:
25/2=12 with remainder 1
12/2=6 with remainder 0
6/2=3 with remainder 0
3/2=1 with remainder 1
1/2=0 with remainder 1 =11001
Base 8:
25/8=3 with remainder 1
3/8= 0 with remainder 3
=31
Base 16:
25/16=1 with remainder 9
1/16= 0 with remainder 1
=19
3. Convert 70(octal) to base 2, 10 and 16
Base 2:
(7)8=111 (0)8=000 =111000
Base 10:
=70 =7(81)+0(80) =56+0 =56
Computing Fundamentals
3
Number System
Base 16:
(7)8=(111)2 (0)8=(000)2 111 000 (70)8 = (111000)2 0011=3 1000=8 =38
4. Convert CD1(hexadecimal) to base 2,10 and 8
CD1 hex to base 2:
(C)16=(1100)2 (D)16=(1101)2 (1)16=(0001)2
1100 1101 0001 110011010001
CD1 hex to base 10:
(CD1)16 C(16*2)+D(16*1)+1(16*0) 12(25*6)+13(16)+1(1) =3281
CD1 hex to base 8: 110011010001
110=6 011=3 010=2 001=1 =6321
Assessments