# Decimal - Binary

Let N = 1 000 … 000 1 (n zeros), and M = 111 … 1110 (n ones). What is the decimal value of M and N assuming:

a) Unsigned Binary Representation

b) Two's compliment Representation

c) Signed/Magnitude Representation

I have figured out that:

a) N = $2^{n+1} + 1$ and $M = 2^{n+1} - 2$

Any help with the rest?

• When you use computer terms like these "representations", you should also include a link to their definitions. – GEdgar Sep 18 '15 at 13:00

b) $N$ is negative. Its complement plus one is: $0 111...111 1$ ($n+1$) ones. Thus,
$$N=-\sum_{i=0}^{n}2^i$$
$M$ is also negative and its complement plus one is: $000...0010$. Thus, $M=-2$.
c) This is easier you just look binary numbers after the sign. Hence, $N$ is negative and $N=-1$. Similarly,
$$M=-\sum_{i=1}^{n-1}2^i$$