What range of numbers encoded using two’s complement representation can be expressed using 5 bits? Provide your answer in decimal.
Solution:
Given,
=>Number of bits = 5
=>2's complement notation is used.
Explanation:
Finding 2's complement number range:
=>Range of numbers encoded in 2's complement with n bits = [-2^(n-1), 2^(n-1) - 1]
=>Range of numbers encoded in 2's complement with 5 bits = [-2^(5-1), 2^(5-1) - 1]
=>Range of numbers encoded in 2's complement with 5 bits = [-2^4, 2^4 - 1]
=>Range of numbers encoded in 2's complement with 5 bits = [-16, 16 - 1]
=>Range of numbers encoded in 2's complement with 5 bits = [-16, 15]
=>Hence range of numbers encoded with 5 bits in 2's complement notation = -16 to +15
I have explained each and every part with the help of statements attached to the answer above.
Get Answers For Free
Most questions answered within 1 hours.