Question: Assume A and B are unsigned 8-bit decimal integers. Calculate A B. Is there overflow, underflow, or neither? Overflow occurs when a result is
Assume A and B are unsigned 8-bit decimal integers. Calculate A – B. Is there overflow, underflow, or neither?
Overflow occurs when a result is too large to be represented accurately given a finite word size. Underflow occurs when a number is too small to be represented correctly—a negative result when doing unsigned arithmetic, for example. (The case when a positive result is generated by the addition of two negative integers is also referred to as underflow by many, but in this textbook, that is considered an overflow.) The following table shows pairs of decimal numbers.
a. b. A 216 185 B 255 122
Step by Step Solution
3.34 Rating (154 Votes )
There are 3 Steps involved in it
To determine if overflow underflow or neither occurs when calculating A B you ne... View full answer
Get step-by-step solutions from verified subject matter experts
