Question
Consider the 8-bit signed integers , and represented using the sign-magnitude form. The binary representations of and are as follows:
Which of the following operations to compute result(s) in an arithmetic overflow?
Official answer and solution
- Official answer
- B and C
- From
- Official GATE 2026 answer key
Solution
Convert and from 8-bit sign-magnitude form to decimal and check which results lie outside the 8-bit sign-magnitude range .
In 8-bit sign-magnitude representation, the MSB is the sign bit ( for , for ) and the remaining bits give the magnitude in , so the representable range is :
- : sign (), magnitude .
- : sign (), magnitude .
Checking each operation:
- (A) (no overflow).
- (B) (overflow).
- (C) (overflow).
- (D) (no overflow).
Options (B), (C)
Using the 2's complement range instead of the sign-magnitude range , which would miss .
The answer is the one in the official GATE answer key. The solution is this site's own explanation.
Source
- Paper
- GATE 2026 Computer Science and Information Technology - Session 1 (CS1)
- Question
- 22 of 65
- Section
- Computer Science and Information Technology
Report an error in this question
GATE questions are the work of the organising institutes. This site is independent and is not affiliated with them.