0

For the following pairs of 4 digit decimal numbers, A and B, show the ten's complement of each, compute A + B and A – B using ten's complement arithmetic, indicate which of the 4 numbers (A, B, A + B, and A – B) are negative (and give their ten's complement), and indicate which of the results (if any) are invalid due to overflow.

a) A = 2929, B = 1414

Hello I am able to subtract them, but do not know how the addition would work and how to detect overflow. Can someone please do this step by step and explain.

  • Is "10 compliment" worth a thousand thanks ? – Jean Marie Mar 21 '17 at 21:39
  • Like two's complement arithmetic, the notion of overflow is only valid when you know the max positive value - for example 127 for an 8 bit value. To answer the overflow question you need to specify the max positive value. Additionally to know whether A and B are negative the max positive value is again needed. For example, if max positive value is 1999 then A is negative. But if max is 9999 then they're both positive, and all the requested quantities are positive. – Χpẘ Mar 22 '17 at 03:30

0 Answers0