Question: 2 0 . When adding two n - bit 2 s complement numbers, overflow will NOT occur, if a . Both operands have different sign
When adding two nbit s complement numbers, overflow will NOT occur, if
a Both operands have different sign bits
b Both operands have same sign bits, and the sign bit of the result is also same
c Carryin bits to MSBs are same as the Carryout bit from the MSB
d All of the above
Consider the following operations on bit twos complement numbers. Which will give
overflow?
a
b
c
d
In Java programming language, the char data type is a single bit Unicode character and
implemented as bit unsigned integer. It has a minimum value of uor and a
maximum value of uffffor inclusive What will be printed when the following code
snippet is executed?
a
b
c
d Run time error
In Java programming language the data type byte is implemented as bit twos complement
integer. What will be printed when the following code snippet is executed?
a
b
c
d Run time error
In Java programming language the data type int is represented as bit twos complement
integer. What will be printed when the following code snippet is executed x means Hex
number Why?
ax because xF x
b because xFFFFFFFF will be
c because xFFFFFFFF will be
dxFFFFFFFG because xF xG
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
