Computer Science 61CL - Spring 2001 - Wawrzynek - Midterm 1

Computer Science 61CL - Spring 2001 - Wawrzynek - Midterm 1...

Info icon This preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
CS61C, Midterm 1 Spring 2001 1) [10 pts] Number Representation Convert the folowing 8-bit numbers from two's complement binary to decimal: 01110011 = 11101101 = Convert the following decimal number to an 8-bit two's complement binary number: -28 = Convert from hex to 16-bit binary: A5B7 = Convert from single precision IEEE floating-point to decimal: 1011111110100000000000000000 = Convert from decimal to single precision IEEE floating-point: 0.125 = 2) [14 pts] Short Answer. For multiple choice and true/false, circle your answer. a) When multiplying two n-bit numbers, what is the maximum number of bits in the result? b) When adding two n-bit numbers, what is the maximum number of bits in the result? c) Write the MIPS instruction that you would use to set to zero all but the lowest (the least significant) bit of register $t0. d) Give the names of two different MIPS instructions that you could use to multiply a value by 2. e) Multiplication of two pointers is a legal operation in the C language. [true false] f) 2's complement representation is commonly used because it simplifies multiplication and division. [true false] g) What is the decimal value of the most negative 2's complement 4-bit number? h) Which of the following instructions specify an address that a linker never needs to resolve? [beq lw j] i) In ten words or less, explain the main disadvantage of interrupts over polling.
Image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern