Final Exam
CMPE 012: Computer Systems and Assembly Language
University of California, Santa Cruz
DO NOT BEGIN UNTIL YOU ARE TOLD TO DO SO.
This exam is closed book and closed notes. Only 4-function calculators are permitted. Answers must be marked on the Scantron form to be graded. All work must be written on the exam.
On the Scantron form, bubble in your name, student ID number, and test form (found in the footer of subsequent pages). In the center of the page write your CruzID, quarter, and exam type. On the back of the page, write the CruzIDs of students sitting to your left and right, and your row and seat number. See below.
On this page, write your last name, first name, CruzID, row and seat numbers, and the CruzIDs of the people to your immediate left and right. Once you are permitted to begin, write your CruzID on all subsequent pages of the exam.
You must sit in your assigned seat. Keep your student or government issued ID on your desk. Brimmed hats must be removed or turned around backwards. Only unmarked water bottles are permitted. Backpacks must be placed at the front of the room or along the walls. Your cell phone must be on a setting where it will not make noise or vibrate.
There are 45 questions on this exam; you only need to answer 42 for full points. The additional three questions (of your choosing) will be counted as extra credit. All questions are multiple choice, and some questions have more than one correct answer. You must mark all correct answers to receive credit for a question. Some true/false questions might list False as answer A and True as answer B. Follow the answers on the exam, NOT the T F notation on the Scantron Form. You will have 120 minutes to complete this exam.
____________________________ ____________________________ ____________________________
Row # Seat #
___________________________________________ Last Name
___________________________________________ CruzID of person to left
CruzID
___________________________________________ First Name
___________________________________________ CruzID of person to right
Bits
1. How many bits are needed to encode one ASCII character? A. 8bits
B. 10bits C. 6bits D. 7bits E. 9bits
2. What is the size of a word in MIPS? Select all that apply. A. 8bytes
B. 32bits C. 8nybbles D. 4bytes E. 32bytes
Binary Arithmetic
3. Perform the following 12-bit two’s complement addition.
0b 0111 1100 0100 + 0b 0000 0001 1100
A. 000011011100 B. 000001010100 C. 011111100001 D. 000010100111 E. 011111100000
4. Which of these 8-bit two’s complement computations has carry out but no overflow? Select all that apply. A. 0x1E + 0x26 = 0x44
B. 0xFA + 0xED = 0xE7
C. 0x0F + 0x85 = 0x94
D. 0x01 + 0x7F = 0x80 E. 0xFF + 0x01 = 0x00
5. A logical right shift and an arithmetic right shift perform the same operation A. True
B. False
CruzID:
@ucsc.edu
CMPE 12 Final Exam – Version A Winter 2019
CMPE 12 Final Exam – Version A Page 1 of 13 Winter 2019
7. What
A. 1235
8. What A.
9. What
is the following 8-bit two’s complement number in signed magnitude form?
B.
C.
D.
E.
-128 to 127 -127 to 128 -128 to 128 -127 to 127
is the following base 9 number in base 5? 1069
B. 3225
C. 7425
D. 3055
E. 2225
is the range of values for an 8-bit two’s complement integer? 0to255
11010110
A. 10110110 B. 10101010 C. 01010110 D. 00101010 E. 11010110
10. Whatisthefollowingbase3numberinbase7?21013 A. 7367
B. 1237 C. 1217 D. 647 E. 467
11. 6-bittwo’scomplement,signedmagnitude,andunsignedallrepresentthesamenumberofintegers,somejust have more negative than positive.
A. True B. False
CMPE 12 Final Exam – Version A Page 2 of 13 Winter 2019
CruzID:
@ucsc.edu
Data Representation
6. Which IEEE 754 single precision floating point number is furthest from zero?
A. 0xC70FFFFF
B. 0x47700000
C. 0x1F8FFFFF
D. 0x380FFFFF
E. 0xB8700000