Unformatted text preview:

CEG 320/520, Homework #1 Ungraded Page 1 of 2 Name: _____________________________ Assume we have an eight-bit machine, and that we are using unsigned eight-bit integers. Perform the following addition operations. For each operation convert both numbers to eight-bit binary numbers, perform the operation, and express the result as an unsigned hex and an unsigned decimal number. Finally, indicate whether unsigned overflow has occurred. EXAMPLE: Binary Unsigned Hex Unsigned Decimal Overflow? 212 11010100+66 +01000010 $16 22 YES00010110PROBLEMS: Binary Unsigned Hex Unsigned Decimal Overflow? 112+23 Binary Unsigned Hex Unsigned Decimal Overflow? 31+72 Binary Unsigned Hex Unsigned Decimal Overflow? 241+30 Binary Unsigned Hex Unsigned Decimal Overflow? 201+112 Binary Unsigned Hex Unsigned Decimal Overflow? 128+44CEG 320/520, Homework #1 Ungraded Page 2 of 2 Assume we have an eight-bit machine, and that we are using signed 2’s complement eight-bit integers. Perform the following addition operations. For each operation, convert both numbers to eight-bit binary numbers, perform the operation, convert the result to 2’s complement hex, and express the result as a signed decimal number. Finally, indicate whether 2’s complement overflow has occurred. EXAMPLE 1: 2’s complement 2’s complement Hex Signed Decimal Overflow? 117 01110101+19 +00010011 $88 -120 YES10001000 PROBLEMS: 2’s complement 2’s complement Hex Signed Decimal Overflow? 82+12 2’s complement 2’s complement Hex Signed Decimal Overflow? 112+17 2’s complement 2’s complement Hex Signed Decimal Overflow? 93-24 2’s complement 2’s complement Hex Signed Decimal Overflow? -61-27 2’s complement 2’s complement Hex Signed Decimal Overflow?


View Full Document

Wright CEG 320 - CEG 320 HOMEWORK # 1

Download CEG 320 HOMEWORK # 1
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view CEG 320 HOMEWORK # 1 and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view CEG 320 HOMEWORK # 1 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?