a) Convert $(121.2)_3$ into base 10
N$=1×3^2+2×3^1+1×3^0+2×3-1 \\
= 9+6+1+0.66\\
= 16.66$
$(121.2)_3=(16.66)_{10}$
b) Represent $(52)_{10}$ into Excess-3 code and Gray code.
Excess-3 code
Separate each digit and represent in their binary format
$\hspace{0.5cm}0 1 0 1\hspace{0.3cm}0 0 1 0$
Now, add 0 0 1 1 to each part

c) Find 1’s complement and 2’s complement of $(57)_{10}$ .
Binary Representation of $(57)_{10}$ is= 1 1 1 0 0 1
i.1’s Complement Representation:-
The one’s complement of binary number is number that results when we change all O’s to one and 1’s to zeros.

ii.2’s Complement Representation:-
The 2’s complement of binary number is number that results when we add 1 to the 1’s complement.
2’s complement = 1’s complement+ 1

d) Obtain hamming code for 1 0 1 1

For P1 : Location 1, 3, 5, 7
$\hspace{1.1cm}$ Bit Location 3, 5 and 7 having three 1’s therefore, to have and an even parity
$\hspace{1.1cm}$ P1 must be 1
For P2 : Location 2, 3, 6 and 7
$\hspace{1.1cm}$ Location bit having two 1’s and therefore,
$\hspace{1.1cm}$ P2 must be 0
For P4 : Location 4, 5, 6, 7
$\hspace{1.1cm}$ Bit Location 5, 6 and 7 having two 1’s therefore,
$\hspace{1.1cm}$ P4 must be 0
Now, hamming code for 1 0 1 1= 1 0 1 0 1 0 1
e) Convert $(126)_{10}$ into Hex and Octal No.
Hexadecimal conversion:

$$(126)_{10}= (7E)_{16}$$

$(126)_{10} =(176)_8$
f) Convert $(214.32)_{10}$ to binary

Conversion of integer part by successive division method

g) Perform Binary subtraction using 2’s complement for $(62)_{10}$ and $(99)_{10}$
- Binary representation for $(62)_{10}$=0 1 1 1 1 1 0
- Binary representation for $(99)_{10}$=1 1 0 0 0 1 1
- Obtain 2’s complement of $(99)_{10}$ =

- Add $(62)_{10}$ to 2’s complement of $(99)_{10}$=

Carry indicates that it is in 2’s complement form and result is negative.
- Take 2’s complement of result=
