testbank-bj-7-ch1
Indicate the answer choice that best completes the statement or answers the question.
1. Which statement best describes a computer program?
a. A program is a sequence of comments.
b. A program can decide what task it is to perform.
c. A program is a sequence of instructions and decisions that the computer carries out.
d. A program can only perform one simple task.
2. Which statement regarding computer programs is correct?
a. Computer programs can decide what task to perform.
b. Large and complex computer programs are generally written by only one programmer.
c. Computer programs are composed of extremely primitive operations.
d. Small computer programs are not documented.
3. What is an example of a typical instruction in a computer program?
a. Add up two numbers.
b. Lay out a term paper.
c. Drive a car.
d. Display a fancy font.
4. What does CPU stand for?
a. Computer Programming Unit
b. Computer Processing Unit
c. Central Processing Unit
d. Central Programming Unit
5. Which one of the following is NOT a function of a CPU?
a. Performing arithmetic operations
b. Processing data and controlling programs
c. Querying a database
d. Fetching and storing data from storage and input devices
6. Which type of storage is made from electronic circuits that can store data?
a. compact disk (CD)
b. hard disk
c. primary storage
d. secondary storage
7. Which one of the following memory types provides storage that persists without electricity?
a. primary storage
b. RAM
c. memory
d. secondary storage
8. Which one of the following memory types provides storage that is slower and less expensive?
Powered by Cognero Page 1
,Name: Class: Date:
testbank-bj-7-ch1
a. primary storage
b. secondary storage
c. peripheral device
d. the transistor
9. Which type of secondary storage consists of rotating platters coated with a magnetic material?
a. hard disk
b. solid state drive
c. compact disk (CD)
d. memory
10. Some computers are self-contained units; others are interconnected through what?
a. bus
b. networks
c. peripheral devices
d. power lines
11. Which is an example of a peripheral device?
a. the CPU
b. primary storage
c. motherboard
d. speakers
12. Which memory type does not provide persistent storage?
a. secondary storage
b. hard disk
c. primary storage
d. DVD
13. Where must program instructions and data reside in order for the CPU to directly read and execute them?
a. memory
b. bus
c. hard disk
d. somewhere on the computer network
14. What term is used to refer to the computer instructions that are executed by a CPU?
a. virtual machine
b. machine code
c. high-level code
d. instruction set
15. What is the Java Virtual Machine?
a. A CPU that runs compiled Java code.
b. A library that makes it possible to write portable programs.
Powered by Cognero Page 2
, Name: Class: Date:
testbank-bj-7-ch1
c. A program that simulates a real CPU running compiled Java code.
d. A program that translates Java code into machine instructions.
16. What is the term used to refer to Java code that runs in a browser?
a. applet
b. script
c. html
d. class
17. What term is used to refer to languages that allow programmers to describe tasks at a higher conceptual level than
machine code?
a. virtual
b. high-level
c. sophisticated
d. conceptual
18. What tool translates high-level instructions into low level machine code?
a. debugger
b. assembler
c. compiler
d. linker
19. What tool translates Java source code into files that contain instructions for the Java Virtual Machine?
a. linker
b. compiler
c. assembler
d. interpreter
20. Which statement is true about running a Java program on a different CPU?
a. You need different Java source code for each CPU.
b. You can take code that has been generated by the Java compiler and run it on different CPUs.
c. You need to compile the Java program for each CPU.
d. You cannot run the program on a different CPU because Java, being a high-level programming language, is
machine dependent.
21. When was Java officially introduced?
a. 1991
b. 1995
c. 2000
d. 2005
22. Which statement best describes the portability characteristic of Java?
a. The same already-compiled Java programs will run on Windows, UNIX, Linux, or Macintosh operating
systems without any change.
b. The same Java compiler can be used on many operating systems.
Powered by Cognero Page 3