Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Given the following decimal numbers: A = 78 B = 47 C = -102 D = -81 Using 8-bit two's complement arithmetic, perform the following
Given the following decimal numbers: A = 78 B = 47 C = -102 D = -81 Using 8-bit two's complement arithmetic, perform the following six calculations as they would be done on an 8-bit microprocessor. Recall that subtraction is performed by negating the second operand and adding, i.e. all operations are performed with a binary adder circuit. A+B A-B A+C A-C C+D C-D For each calculation, show the 8-bit result (and check that it corresponds to the correct decimal value), and also show the state (1 or 0) of each of the following "condition codes": Z = result zero N = result negative C = carry out of the most significant bit V = signed overflow For example: 5-10 = 00000101 - 00001010 = 00000101 +11110110 = 11111011 = -00000101 = -5 N = 1 (result negative) Z = 0 (result not zero) C = 0 (no carry out of MSB of adder) V = 0 (no signed overflow)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started