1、Chapter 1 Computer and DataKnowledge point:1.1 The computer as a black box.1.2 von Neumann model 1.3 The components of a computer: hardware, software, and data. 1.4 The history of computers.REVIEW QUESTIONS1. How is computer science defined in this book?A:Issues related to the computer.2. What model
2、 is the basis for todays computers? ( Knowledge point 1.2)A:The von Neumann model.3. Why shouldnt you call a computer a data processor? ( Knowledge point 1.1)A:Computer is general-purpose machine. it can do many different types of tasks.4. What does a programmable data processor require to produce o
3、utput data? ( Knowledge point 1.1)A:The input data and the program.5. What are the subsystems of the von Neumann computer model? ( Knowledge point 1.2)A:Memory, arithmetic logic unit, control unit, and input/output.6. What is the function of the memory subsystem in von Neumanns model? ( Knowledge po
4、int 1.2)A:Memory is the storage area. It is where programs and data are stored during processing.7. What is the function of the ALU subsystem in von Neumanns model? ( Knowledge point 1.2)A:ALU is where calculation and logical operations take place.8. What is the function of the control unit subsyste
5、m in von Neumanns model? ( Knowledge point 1.2)A:It controls the operations of the memory, ALU, and the input/output subsystem.9. What is the function of the input/output subsystem in von Neumanns model? ( Knowledge point 1.2)A:The input subsystem accepts input data and the program from outside the
6、computer; the output subsystem sends the result of processing to the outside.10. Compare and contrast the memory contents of early computers with the memory contents of a computer based on the von Neumann model? ( Knowledge point 1.2)A:Computer based on the von Neumann model stores both the program
7、and its corresponding data in the memory. Early computers only stored the data in the memory.11. How did the von Neumann model change the concept of programming? ( Knowledge point 1.2)A:A program in the von Neumann model is made of a finite number of instructions. The instructions are executed one a
8、fter another.12. The first electronic special-purpose computer was called c ( Knowledge point 1.4)a. Pascal b. Pascaline c. ABC d. EDVAC13. One of the first computers based on the von Neumann model was called d ( Knowledge point 1.4)a. Pascal b. Pascaline c. ABC d. EDVAC14. The first computing machi
9、ne to use the idea of storage and programming was called d ( Knowledge point 1.4)a. the Madeline b. EDVAC c. the Babbage machine d. the Jacquard loom15. d separated the programming task from the computer operation tasks. ( Knowledge point 1.3)a. Algorithms b. Data processors c. High-level programmin
10、g languages d. Operating systems30. According to the von Neumann model, can the hard disk of today be used as input or output? Explain. ( Knowledge point 1.2)A:Yes. When the hard disk stores data that results from processing, it is considered an output device; when you read data from the hard disk,
11、it is considered an input device.32. Which is more expensive today, hardware or software? ( Knowledge point 1.3)A:Software.Chapter 2 Data RepresentationKnowledge point:2.1 Data Types.2.2 Data inside the Computer.2.3 Representing Data.2.4 Hexadecimal and Octal notation.REVIEW QUESTIONS1. Name five ty
12、pes of data that a computer can process. ( Knowledge point 2.1)A:Numbers, text, images, audio, and video.2. How does a computer deal with all the data types it must process? ( Knowledge point 2.2)A:All data types are transformed into bit pattern.3.4. What is the difference between ASCII and extended
13、 ASCII? ( Knowledge point 2.3)A:ASCII is a bit pattern made of 7 bits and extended ASCII is a bit pattern made of 8 bits.5. What is EBCDIC? ( Knowledge point 2.3)A:Extended Binary Coded Decimal Interchange Code.6. How is bit pattern length related to the number of symbols the bit pattern can represe
14、nt? ( Knowledge point 2.3)A:The relationship is logarithmic.7.8.9. What steps are needed to convert audio data to bit patterns? ( Knowledge point 2.3)A:Sampling, Quantization, and Coding.10. What is the relationship between image data and video data? ( Knowledge point 2.3)A:Video is a representation
15、 of images in time.34. A company has decided to assign a unique bit pattern to each employee. If the company has 900 employees, what is the minimum number of bits needed to create this system of representation? How many patterns are unassigned? If the company hires another 300 employees, should it i
16、ncrease the number of bits? Explain your answer. ( Knowledge point 2.3)A:log290010, 210-900=124, Yes, 900+300210Chapter 3 Number RepresentationKnowledge point:3.1 Convert a number from decimal, hexadecimal, and octal to binary notation and vice versa.3.2 Integer representation: unsigned, sign-and-ma
17、gnitude, ones complement, and twos complement.3.3 Excess system.3.4 Floating-point representation.REVIEW QUESTIONS5. What are three methods to represent signed integers? (Knowledge point 3.2) A:Sign-and-Magnitude, Ones Complement, and Twos Complement.9. Name two uses of unsigned integers. ( Knowledg
18、e point 3.2)A:Counting and Addressing.10. What happens when you try to store decimal 130 using sign-and-magnitude representation with an 8-bit allocation? ( Knowledge point 3.2)A:Overflow.11. Compare and contrast the representation of positive integers in sing-and-magnitude, ones complement, and two
19、s complement. ( Knowledge point 3.2)A:The representation of positive integers in sing-and-magnitude, ones complement, and twos complement is the same.14. Compare and contrast the range of numbers that can be represented in sign-and-magnitude, ones complement, and twos complement. ( Knowledge point 3
20、.2)A:Sign-and-Magnitude range (2N-1-1)+(2N-1-1) Ones Complement range (2N-1-1)+(2N-1-1) Twos Complement range (2N-1)+(2N-1-1)16. What is the primary use of the Excess_X system? ( Knowledge point 3.3) A:The primary use of the Excess_X system is in storing the exponential value of a fraction.17. Why i
21、s normalization necessary? ( Knowledge point 3.4)A:A fraction is normalized so that operations are simpler.Chapter 4 Operation On BitsKnowledge point:4.1 Arithmetic operations.4.2 Logical operations.4.3 Mask.4.4 Shift operations.REVIEW QUESTIONS3. What happens to a carry form the leftmost column in
22、the final addition? ( Knowledge point 4.1) A:The carry is discarded.5. Define the term overflow. ( Knowledge point 4.1)A:Overflow is an error that occurs when you try to store a number that is not within the range defined by the allocation.8. Name the logical binary operations. ( Knowledge point 4.2
23、)A:NOT, AND, OR, and XOR.10. What does the NOT operator do? ( Knowledge point 4.2)A:It inverts bits.(it changes 0 to 1 and 1 to 0)11. When is the result of an AND operator true? ( Knowledge point 4.2)A:Both bits are 1.12. When is the result of an OR operator true? ( Knowledge point 4.2)A:Neither bit
24、 is 0.13. When is the result of an XOR operator true? ( Knowledge point 4.2)A:The two bits are not equal.17. What binary operation can be used to set bits? What bit pattern should the mask have? ( Knowledge point 4.3)A:OR. Use 1 for the corresponding bit in the mask.18. What binary operation can be
25、used to unset bits? What bit pattern should the mask have? ( Knowledge point 4.3)A:AND. Use 0 for the corresponding bit in the mask.19. What binary operation can be used to flip bits? What bit pattern should the mask have? ( Knowledge point 4.3)A:XOR. Use 1 for the corresponding bit in the mask.Chap
26、ter 5 Computer OrganizationKnowledge point:5.1. three subsystems that make up a computer5.2. functionality of each subsystem5.3. memory addressing and calculating the number of bytes5.4. addressing system for input/output devices.5.5. the systems used to connect different components together.Review
27、questions:1. What are the three subsystems that make up a computer?(Knowledge point 5.1)Answer: the CPU, main memory, and the input/output (I/O) subsystem.2. What are the parts of a CPU? (Knowledge point 5.1)Answer: The CPU performs operations on data and has a ALU, a control unit, and a set of regi
28、sters.3. Whats the function of the ALU? (Knowledge point 5.2)Answer: The ALU performs arithmetic and logical operations.Exercises:78. A computer has 64MB of memory. Each word is 4 bytes. How many bits are needed to address each single word in memory? (Knowledge point 5.3)Solution:The memory address
29、space is 64 MB, that is 2 raised to the power 26. The size of each word in bytes is 2 raised to the power 2. So we need 24(subtract 2 from 26) bits to address each single word in memory.79. How many bytes of memory are needed to store a full screen of data if the screen is made of 24 lines with 80 c
30、haracters in each line? The system uses ASCII code, with each ASCII character store as a byte. (Knowledge point 5.3)Solution:The quantity of bytes in a full screen is 1920 (24*80) while the system uses ASCII code with each ASCII character store as a byte. So we need 1920 bytes of memory to store the
31、 full screen of data.87. A computer uses isolated I/O addressing. Memory has 1024 words. If each controller has 16 registers, how many controllers can be accessed by this computer? (Knowledge point 5.4)Solution:Memory has 1024 words. So the address space is 1024. Each controller has 16 registers. Th
32、en we get 64 (divide 16 by 1024)controllers which can be accessed by this computer. 88. A computer uses memory-mapped I/O addressing. The address bus uses 10 lines. If memory is made of 1000 words, how many four-register controllers can be accessed by this computer? (Knowledge point 5.4)Solution:The
33、 address bus uses 10 lines. So, the address space is 1024(2 raised to the power 10). The memory is made of 1000 words and each controller has four registers. Then we get (1024-1000)/4 = 6 four-register controllers which can be accessed by this computer.Chapter 6 Computer NetworksKnowledge point:6.1.
34、 OSI model6.2. TCP/IP protocol6.3. three types of networks6.4. connecting devices6.5. client-server modelReview questions:2. Name the layers of the OSI model? (6.1)Answer: Physical layer, Data link layer, Network layer, Transport layer, Session layer, Presentation layer and Application layer.3. Name
35、 the layers of the TCP/IP protocol suite. (6.2)Answer: The layers of the TCP/IP protocol suite are: physical and data-link layers network layer, transport layer, and application layer.8. What are the three common topologies in LANs? Which is the most popular today? (6.3)Answer: bus topology, star to
36、pology, ring topology, star topology9. Name four types of network connecting devices. (6.4)Answer: the four types of network connecting devices are repeater, bridge, router and gateway.Chapter 7 Operating SystemsKnowledge point:7.1. the definition of an operating system7.2. the components of an oper
37、ating system7.3. Memory Manager7.4. Process manager7.5. deadlockReview questions:4. What are the components of an operating system? (7.2)Answer: An operating system includes: Memory Manager, Process Manager, Device Manager and File Manager13. What kinds of states can a process be in? (7.4)Answer: re
38、ady state, running state, waiting state.15. If a process is in the running state, what states can it go to next? (7.4)Answer: ready state, waiting state.Whats the definition of an operating system? (7.1)Answer: An operating system is an interface between the hardware of a computer and user(programs
39、or humans) that facilitates the execution of other programs and the access to hardware and software resources.What are the four necessary conditions for deadlock? (7.5)Answer: mutual exclusion, resource holding, no preemption and circular waiting. 51. A multiprogramming operating system uses paging.
40、 The available memory is 60 MB divided into 15 pages, each of 4MB. The first program needs 13 MB. The second program needs 12MB. The third program needs 27 MB. How many pages are used by the first program? How many pages are used by the second program? How many pages are used by the third program? H
41、ow many pages are unused? What is the total memory wasted? What percentage of memory is wasted? (7.3)Answer:Each page is 4MB. The first program needs 13 MB. It is obviously that 4*3134*4. So the first program uses 4 pages and wastes 3(16-3) MB. The second program needs 12 MB. It is obviously that 12=4*3. So the second program uses 3 pages and wastes 0 MB. The third program needs 27 MB. It is obviously that 4*627k0