Multiple choice

If any signed integer data type takes 4 bytes, what maximum value can be stored?

    • 24
    • 232 - 1
    • 231
    • 231 - 1
Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

If any signed integer data type takes n bytes, the range of that data type will be -28n-1 to +28n-1 - 1. In this case, n = 4.  The maximum value stored = +28 x 4 - 1 - 1 = + 231 - 1