Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

PLEASE ANSWER 5, 6, AND 7 AND SHOW WORK THANK YOU!!! (50 pts) CS3843 CompOrg Exa

ID: 3903940 • Letter: P

Question

PLEASE ANSWER 5, 6, AND 7 AND SHOW WORK THANK YOU!!!

(50 pts) CS3843 CompOrg Exam #1 Name/abc123: Conversions: (50 pts) 1. (8 pts) Convert the following decimal numbers to hexadecimal. Assume 8-bits a. -55 b. 152 2. (8 pts) Convert the following hexadecimal values to decimal. Assume 8-bits and show the signed and unsigned values. a. 0x86 Signed Unsigned: b. 0xFE Signed: Unsigned: 3. (4 pts) Convert the binary number to hex and the hex number to binary a. 11100101010012 b. OxB15 4. (8 pts) For the numbers below, perform the operations as dictated byte the table. (Hint: last 3, use binary) ADD 0xAC 0x92 OR 0xAC 0x92 AND 0xAC 0x92 XOR OxAC 0x92 Operations: Results: 5. (4 pts) For the ADD instruction, what is the valuc of the following flags after the operation: (Assume 8 bits.) a. CF: ZF 6. (2 pts) What hex number would you add to 0x3D to set the ZERO flag? 2017 01-CS 3843 Computer Organization-Exam #1 Page 1

Explanation / Answer

HI please go threw the solution.

5)

0xAC 1010 1100

+0x92 1001 0010

ans- 0x13E 10011 1110

CF = 1, SF = 0, OF = 1 ZF =0

6)

0x3D

+(- 0x3D)

ans 0x00

so ,

2's compliment of 0x3D

0011 1101

-> 1100 0010

-> 1100 0011

so, now add these two numbers

0011 1101

1100 0011

ans- 10000 0000

so, ZF =0

7)

a) 0x8F SAR::hex:0x08 decimal = 8

befor -> 1000 1111

0010 0011

after -> 0000 1000

b) 0xFB SAR::hex=0x0F decimal = 15

befor -> 1111 1011

0011 1110

after -> 0000 1111