practicemidterm1

practicemidterm1 - ECEn 324 Practice Exam: Midterm #1 1. a....

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
Rev. 3.0 1 ECEn 324 Practice Exam: Midterm #1 1. Which of the following was developed as part of the GNU project? a. The C programming language b. The GCC compiler c. The Linux operating system d. The Unix operating system 2. Which of the following statements is false? a. In different contexts, the same sequence of bytes might represent an integer, a floating point number, a character string, or a machine instruction. b. C was developed as the systems programming language for Unix. c. According to Chapter 1, it is the linker that produces a relocatable object file. d. The operating system provides the illusion that the current program is the only one running. 3. On a little-endian machine, if the 32-bit value stored at address A is 0x12345678 , then the value of the byte at address A is a. 0x12 b. 0x34 c. 0x56 d. 0x78 4. On a 64-bit machine, variables of which of the following C data types are most likely to have 8 bytes allocated for their storage? a. char * b. short c. int d. float 5. Which of the following C expressions has a result value of 0x01 ? a. !0x7f b. !!0x00 c. !(~0) d. e. 0x0102 && (0xff << 8) 6. Assuming that they represent two’s complement integers on a 16-bit machine, which of the following has the greatest absolute value? a. 0xffff b. 0x00ff c. 0xc000 d. 0xe000 7. Which of the following is NOT true? a. Unsigned and two’s complement addition can both be done with the same instruction. b. Unsigned and two’s complement multiplication can be done with the same instruction. c. With two’s complement numbers, multiplication by a power of two always equals a left shift. d. With two’s complement numbers, division by a power of two always equals a right shift.
Background image of page 1

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

View Full DocumentRight Arrow Icon
Rev. 3.0 2 8. Consider a tiny floating-point representation with a sign bit, 2 exponent bits, 2 fraction bits, and otherwise following the conventions of IEEE floating-point formats. In this tiny format, which of the following bit patterns corresponds to the numerical value of +1 10 ? a.
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 6

practicemidterm1 - ECEn 324 Practice Exam: Midterm #1 1. a....

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online