Tuesday

October 21, 2014

October 21, 2014

Posted by **Francesca** on Thursday, September 8, 2011 at 7:05pm.

a.) +18

b) -117

Thanks for any help!

- Computing in Security (Conversion Help) -
**MathMate**, Thursday, September 8, 2011 at 11:02pmTwo's complement is a notation that represents both positive and negative numbers. The most significant (left-most) is the sign bit, which is turned on when the number is negative.

Unlike the one's complement, there is only one representation of zero.

For an eight-bit number, the range goes from -128 to 127.

A positive number is represented by a usual binary number format, using the 7 low-order (right-most) bits, and represent from 0 to 127.

A negative number is simply the reversal of the bits and then add 1.

Example:

10(decimal)=00001010(binary)

-10(decimal)=11110101 + 1

=11110110

18(decimal)=00010010(binary)

-18(decimal)=11101101 + 1

=11101110

and so on.

To negate a negative number, subtract one and reverse the bits.

For example,

-18(decimal)=11101110

subtract 1

11101101

Reverse bits

00010010 (binary -18)

**Answer this Question**

**Related Questions**

computer or math - pls help me to solve this question. thank you very much ...

computer science - a) What is the largest positive number that can be ...

math - The following numbers can be represented as 8-bit numbers in the binary ...

computer science - What is the binary representation of the following ...

computers - digital logic design ( i have a lot questios so please help me) ...

computer science /use java language - write the program that inputs a string ...

math - it is required to find a rational number which is equal to the recurring ...

programming 2 - Write a program that inputs a word representing a binary number...

Computing in Security (Conversion Help) - 1.) Encrypt the hexadecimal message ...

Computer/assembly language - Write a procedure BCD to convert a hexadecimal ...