উত্তর
ব্যাখ্যা
or an 8-bit signed integer, one bit is used for the sign (positive or negative) and the remaining 7 bits are used to represent the magnitude of the number.
• The most significant bit (MSB) is used as the sign bit:
-> 0 indicates a positive number.
-> 1 indicates a negative number.
• For positive numbers (when the MSB is 0), the remaining 7 bits can represent values from 0 to 127 (which is 27−1).
• For negative numbers (when the MSB is 1), the values are represented in two's complement. In two's complement, the most negative value is −27, or -128, and the most positive value is +127.
The range for an 8-bit signed integer is from -128 to +127.
Source: Digital Logic & Computer Design By M. Morris Mano