in Digital Logic retagged by
476 views
5 votes
5 votes

In two's complement, what is the minimum number of bits needed to represent the numbers $-1$ and the number $1$ respectively?

  1. $1$ and $2$
  2. $2$ and $2$
  3. $2$ and $1$
  4. $1$ and $1$
in Digital Logic retagged by
476 views

1 Answer

6 votes
6 votes
$-1$ in Twos complement is $1$.

$1$ in Twos complement is $01$.

With $n-bits$, we can represent $-2^{n-1}$ to $2^{n-1} -1 $ numbers in Twos complement number system.

3 Comments

good question..
I misinterpreted question as we want to represent -1 and 1 simultaneously..
2
2

@krishnajsw can u plz explain a little? 

0
0

@trail
using 1 bit you can represent number between -2^(1-1) to (2^(1-1) - 1)  -> -1 to 0
using 2 bit you can represent number between -2^(2-1) to (2^(2-1) - 1) -> -2 to 1
so to represent -1 -> 1 bit is enough
to represent 1 -> 2 bit required

3
3
Answer:

Related questions