Question

Assume that a mad scientist has created a computer that has 9 bit registers. The most...

Assume that a mad scientist has created a computer that has 9 bit registers. The most significant bit is the sign bit. He wants to execute the following operation using 9 bit register. -256 - 2 Use 2's complement method (in binary) to find the result of the above operation in binary system. Show the computations in the answer. a Formar CB I U A Addit Record Audio

Homework Answers

Answer #1

256 = 100000000 (Cannot be stored in a 9-bit signed variable)

-256 = 011111111 + 1 = 100000000 (Can be stored in a 9-bit signed variable & this is also the smallest value that can be stored)

2 = 000000010

we know that A - B = A + (B' + 1)   in 2's Complement method

so ANS = 100000000 + (000000010' + 1)

             = 100000000 + (111111101 + 1) = 100000000 + 111111110

             = 1 011111110

The last carry over bit being 1 signifies that the result of the operation is negative and has also gone out of bounds of the limit of a 9-bit register to store the data, thereby resulting in an error or otherwise an incorrect result as +254.

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT