Programming Question
CSC 261: Computer Organization and Assembly Language
Spring 2024
Assignment 2
Question 1 (20 points):
(a) Find the range of unsigned decimal integers that can be stored in a dword.
(b) Find the range of signed decimal integers (smallest to largest) that can be stored in
2’s complement form in a dword.
Question 2 (20 points): Perform the addition operation, giving the sum in hex using the
same number of hex digits as the original two operands; State whether or not overflow
and carry occur; Interpret the operations as 2’s complement signed and convert the
problem to the equivalent decimal problem; Verify that the signed interpretation is
correct when there is no overflow; Interpret the operands as unsigned and convert the
problem to the equivalent decimal problem; Verify that the unsigned interpretation is
correct when there is no carry.
2A 44 + D9 CC
Note: See chapter 1 slides. I did a bunch of questions similar to this.
Question 3 (20 points): Instructions are the same as in Question 2 but repeat them for 5E
+ 4B.
Question 4 (20 points): Consider the byte length 2’s complement representation and show
that FF is -1. Now consider the word length 2’s complement representation of FF FF and
show that it is also -1.
Question 5 (20 points): We learned how to take the 2’s complement of a number by
subtracting it from an appropriate power of 2. An alternative method is to write the
number in binary (using the correct number of bits for the length of the representation),
change each 0 bit to 1 and each 1 bit to 0 (this is called “taking the 1’s complement”),
and then adding 1 to the result (discarding any carry into an extra bit). Show that these
Collepals.com Plagiarism Free Papers
Are you looking for custom essay writing service or even dissertation writing services? Just request for our write my paper service, and we'll match you with the best essay writer in your subject! With an exceptional team of professional academic experts in a wide range of subjects, we can guarantee you an unrivaled quality of custom-written papers.
Get ZERO PLAGIARISM, HUMAN WRITTEN ESSAYS
Why Hire Collepals.com writers to do your paper?
Quality- We are experienced and have access to ample research materials.
We write plagiarism Free Content
Confidential- We never share or sell your personal information to third parties.
Support-Chat with us today! We are always waiting to answer all your questions.