Add +25 to -15 by using 2's complement ?Ans. Firstly convert the numbers 25 and 15 in its 8-bit binary equivalent and determine the 2's complement of 15, after that add +25 to -15. 15= 0 0 0 0 1 1 1 1 (8-bit binary equivalent of 15)
= 1 1 1 1 0 0 0 0 (1's complement) +1 ------------------------------
= -15 = 1 1 1 1 0 0 0 1 (2's complement of 15) +25 = 0 0 0 1 1 0 0 1 (8-bit binary equivalent of 25) ------------------------------ Addition of -15 to +25 +10 = 0 0 0 0 1 0 1 0 ------------------------------- Thus -15 to +25 = (10)_{10} = (1010)_{2}.