Computer Science Illuminated
Computer Science Illuminated
7th Edition
ISBN: 9781284155617
Author: Nell Dale, John Lewis
Publisher: Jones & Bartlett Learning
Expert Solution & Answer
Book Icon
Chapter 3, Problem 39E

Explanation of Solution

a.

To prove: “Adding one to nine’s complement of a number is equal to ten’s complement of the same number”.

Proof:

Formula for ten’s complement to compute the number:

Negative(I) = 10k  I         (1)

In the above formula,

  • “k” represents the number of digits.
  • “I” represents the number to be calculated.

Formula for nine’s complement to compute the number:

Negative[I]=9999....I

In the above formula,

  • “I” represents the number to be calculated.
  • “9999….” represents all 9s in which the number of 9s should be equal to the number of digits in a given number “I”.

Adding one to Nine’s complement formula to calculate the numbers:

Negative[I]=(9999....I)+1        (2)

Comparing Equation (1) and Equation (2),

10kI=(9999....I)+110kI=9999....I+110kI+I=9999

Explanation of Solution

b.

Calculating ten’s complements using nine’s complement plus one formula for “-35768”:

Nine’s complement plus one formula to compute the numbers:

Negative[I]=(9999....I)+1

Negative[35768]=(9999935768)+1=64231+1=64232

Therefore, ten’s complement using nine’s complement plus one formula for “-35768” is “64232”.

Calculating ten’s complements using nine’s complement plus one formula for “-444455”:

Nine’s complement plus one formula to compute the numbers:

Negative[I]=(9999...

Explanation of Solution

c.

Nine’s complement plus one method is easier.

Justification:

  • Borrowing of values are needed for subtraction in direct ten’s complement method but in nine’ complement plus one method, borrowing of values are not needed for subtraction...

Blurred answer
Knowledge Booster
Background pattern image
Recommended textbooks for you
Text book image
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Text book image
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Text book image
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
Text book image
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Text book image
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Text book image
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education