Arora Educator
Binary Addition & Subtraction
Arora Educator
#1 = Binary Addition Rule
Arora Educator
Binary Addition Rule
Arora Educator
Q.1. Add 1001 and 111
1001 1001 = 8421 = 9
0111 0111 = 8421 = 7
_____ 9+7 = 16 = 16 8 4 2 1 = 10000
10000
Arora Educator
Q.2. Add 101 and 011
101
011
_____
1000
Arora Educator
Q.3. adding 11 to 13
11 = 8 4 2 1 = 1 0 1 1
13 = 8 4 2 1 = 1 1 0 1
11 + 13 = 24
1011 16 8 4 2 1
1101 1 1000
_____
11000
#2 = Binary Subtraction Rule Arora Educator
Arora Educator
Q.1. 1010 – 101
1 0 1 0 = 8 4 2 1 = 10
101=8421=5
10-5 = 5 = 8 4 2 1 = 0 1 0 1
Arora Educator
Q.2. 1100 – 0111
1 1 0 0 = 8 4 2 1 = 12
0111=8421=7
12-7 = 5 = 8 4 2 1 = 0 1 0 1
Arora Educator
Q.3. 100 – 1
100=421=4
1=1
4-1 =3=8421= 0011
Arora Educator
Complements in Computer
Architecture
✓ Complement means = something that
completes or makes perfect
✓ Used in = Digital Circuit
✓ Simplify the = subtraction operation
✓ Simplify the = logical manipulations
✓ The complement of a 1 is = 0
Arora Educator
1’s Complement
Arora Educator
1’s Complement
Q.1 - 1’s complement of binary number 110010 is
Answer = 001101
Q.2 - Find 1’s complement of binary number 10101110
Answer = 01010001
Arora Educator
1’s Complement
Q.3 - Find 1’s complement of decimal number 45.?
Answer
45 = 32 16 8 4 2 1
= 1 0 1 1 0 1
1’s = 0 1 0 0 1 0
Arora Educator
1’s Complement
Q.4 - Find 1’s complement of decimal number 45
in 8 Bit.?
Answer
45 = 32 16 8 4 2 1
=1 0 1 1 0 1
8 Bit = 0 0 1 0 1 1 0 1
1’s = 11010010
Arora Educator
1’s Complement
Q.6 – Find 1’s complement of decimal number +8 .?
Answer
+ means = 0 (Add in Left Side)
+8 = + 8 4 2 1
Note = No need to reverse the number
= 01000
Arora Educator
1’s Complement
Q.9 – Find 1’s complement of decimal number -8 .?
Answer
- means = 1
+8 = + 8 4 2 1
Note = - 8 = +8
= 01000
Then 1’s Complement
1’ = 1 0 1 1 1
Arora Educator
2’s Complement
Arora Educator
2’s Complement
Q.1 – Obtain 2’s Complement of (110100)2
Answer
To get 2’s complement of a binary number-
1) Find 1’s complement = 001011
2) Now add 1 to the LSB of this number
0 0 1 1 0 0
Arora Educator
2’s Complement
Q.2 – Obtain 2’s Complement of (1010100)2
Answer
To get 2’s complement of a binary number-
1) Find 1’s complement = 0101011
2) Now add 1 to the LSB of this number
0 1 0 1 1 0 0
Arora Educator
9’s Complement
Q.1. 9’s Complement of 45 is.? Arora Educator
9’s Complement of 45 is =
Subtracting each digit by 9
99 - 45 = 54
Q.2. Find 9’s Complement of BCD 45 is.? Arora Educator
9’s Complement of 45 is =
Subtracting each digit by 9
99 - 45 = 54
Now BCD of 54 is
5 = 0101
4 = 0100
= 0101 0100
Arora Educator
10’s Complement
Q.1. 10’s Complement of 455 is.? Arora Educator
10’s Complement of 455 is =
10’s Complement = 9’s Complement + 1
9’s Complement = 999 - 455 = 544
10’s Complement = 544 + 1 = 545
Q.2. 10’s Complement of BCD 28 is.? Arora Educator
10’s Complement of 28 is =
Subtracting each digit by 9
99 - 28 = 71 + 1 = 72
Now BCD of 72 is
7 = 0111
2 = 0010
Ans = 0111 0010