Kapitel 1 Flashcards
Iist the five major hardware components of a computer system.
The Central Processing Unit (CPU), main memory, secondary storage devices, input devices, output devices.
Why is the computer used by so many different people, in so many different professions?
Because the computer can be programmed to do so many different tasks.
Internally, the CPU consists of what two units?
Arithmetic and Logic Unit (ALU), and Control Unit.
Describe the steps in the fetch/decode/execute cycle.
Fetch: The CPU’s control unit fetches the program’s next instruction from main memory.
Decode: The control unit decodes the instruction, which is encoded in the form of a number. An electrical signal is generated.
Execute: The signal is routed to the appropriate component of the computer, which causes a device to perform an operation.
What is a memory address? What is its purpose?
A unique number assigned to each section of memory. The address is used to identify a location in memory.
Explain why computers have both main memory and secondary storage.
Program instructions and data are stored in main memory while the program is operating. Main memory is volatile, and loses its contents when power is removed from the computer. Secondary storage holds data for long periods of time—even when there is no power to the computer.
What does the term multitasking mean?
It means that an operating system is capable of running multiple programs at once.
Describe the difference between a key word and a programmer-defined symbol.
A key word has a special purpose, and is defined as part of a programming language. A programmer-defined symbol is a word or name defined by the programmer.
Describe the difference between operators and punctuation symbols.
Operators perform operations on one or more operands. Punctuation symbols mark the beginning or ending of a statement, or separates items in a list.
Describe the difference between a program line and a statement.
A line is a single line as it appears in the body of a program. A statement is a complete instruction that causes the computer to perform an action.
Why are variables called “variable”?
Because their contents may be changed.
What happens to a variable’s current contents when a new value is stored there?
The original value is overwritten.
What is a compiler?
A compiler is a program that translates source code into an executable form.
What is a syntax error?
Syntax errors are mistakes that the programmer has made that violate the rules of the programming language. These errors must be corrected before the compiler can translate the source code.
What is byte code?
The Java compiler translates Java source code into byte code, which is an intermediate language. The Java Virtual Machine executes the byte code instructions.