Deck 1: Introduction to Computers and Java
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/40
Play
Full screen (f)
Deck 1: Introduction to Computers and Java
1
__________ refers to the physical components that a computer is made of.
A) Input
B) Main memory
C) Control unit
D) Hardware
A) Input
B) Main memory
C) Control unit
D) Hardware
D
2
RAM is usually
A) an input/output device
B) a volatile type of memory, used for temporary storage
C) secondary storage
D) a static type of memory, used for permanent storage
A) an input/output device
B) a volatile type of memory, used for temporary storage
C) secondary storage
D) a static type of memory, used for permanent storage
B
3
Each byte is assigned a unique number known as an address.
True
4
A procedure is a set of programming language statements that, together, perform a specific task.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
5
While __________ is centered on creating procedures, __________ is centered on creating objects.
A) procedural programming, object-oriented programming
B) object-oriented programming, procedural programming
C) routine programming, method programming
D) procedural programming, class programming
A) procedural programming, object-oriented programming
B) object-oriented programming, procedural programming
C) routine programming, method programming
D) procedural programming, class programming
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
6
Logical errors are mistakes that cause the program to produce erroneous results.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
7
A solid-state drive has no moving parts and operates faster than a traditional disk drive.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
8
The Java Virtual Machine is a program that reads Java byte code instructions and executes them as they are read.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
9
Validating the results of a program is important to
A) correct runtime errors
B) make sure the program solves the original problem
C) create a model of the program
D) correct syntax error
A) correct runtime errors
B) make sure the program solves the original problem
C) create a model of the program
D) correct syntax error
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
10
Which of the following commands will run the compiled Java program named DoItNow?
A) run DoItNow
B) java DoItNow.java
C) java DoItNow
D) go DoItNow
A) run DoItNow
B) java DoItNow.java
C) java DoItNow
D) go DoItNow
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
11
Variables are
A) symbolic names made up by the programmer and once created, their values cannot be changed
B) operators that perform operations on one or more operands
C) symbolic names made up by the programmer that represent memory locations
D) reserved words
A) symbolic names made up by the programmer and once created, their values cannot be changed
B) operators that perform operations on one or more operands
C) symbolic names made up by the programmer that represent memory locations
D) reserved words
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
12
Software refers to
A) programs
B) the physical components a computer is made of
C) firmware
D) data stored in RAM
A) programs
B) the physical components a computer is made of
C) firmware
D) data stored in RAM
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
13
Java source files end with the .class extension.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
14
Assume you are at the operating system command line and want to use the following command to compile a program:
javac MyClass.java
Before entering the command you must
A) close all open windows on your computer system
B) make sure you are in the same directory or folder where the MyClass.java file is located
C) execute the java.sun.com program
D) save the program with the .comp extension
javac MyClass.java
Before entering the command you must
A) close all open windows on your computer system
B) make sure you are in the same directory or folder where the MyClass.java file is located
C) execute the java.sun.com program
D) save the program with the .comp extension
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
15
An object typically hides its data but allows outside code access to
A) the pseudocode
B) the methods that operate on the data
C) private data members
D) the data files
A) the pseudocode
B) the methods that operate on the data
C) private data members
D) the data files
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
16
The two primary methods of programming in use today are
A) procedural and object-oriented
B) hardware and software
C) practical and theoretical
D) desktop and mobile
A) procedural and object-oriented
B) hardware and software
C) practical and theoretical
D) desktop and mobile
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
17
Application software refers to programs that make the computer useful to the user.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
18
Compiled byte code is also called source code.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
19
Encapsulation refers to the combining of data and code into a single object.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
20
Colons are used to indicate the end of a Java statement.
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
21
A(n) __________ is used to write computer programs.
A) pseudocode document
B) operating system
C) application
D) programming language
A) pseudocode document
B) operating system
C) application
D) programming language
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
22
Because Java byte code is the same on all computers, compiled Java programs
A) are nonexistent
B) must be re-compiled for each different machine before they can be run
C) are highly portable
D) cannot run on computers with different operating systems
A) are nonexistent
B) must be re-compiled for each different machine before they can be run
C) are highly portable
D) cannot run on computers with different operating systems
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
23
The end of a Java statement is indicated by a ________.
A) bracket (})
B) asterisk (*)
C) semicolon (;)
D) colon (:)
A) bracket (})
B) asterisk (*)
C) semicolon (;)
D) colon (:)
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
24
Computers can do many different jobs because they are
A) programmable
B) reliable
C) automated
D) electronic
A) programmable
B) reliable
C) automated
D) electronic
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
25
A(n) __________ is a software entity that contains data and procedures.
A) object
B) program
C) class
D) method
A) object
B) program
C) class
D) method
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
26
The central processing unit (CPU) consists of two parts which are
A) the input and output devices
B) the control unit and the arithmetic and logic unit (ALU)
C) the control unit and main memory
D) the arithmetic and logic unit (ALU) and main memory
A) the input and output devices
B) the control unit and the arithmetic and logic unit (ALU)
C) the control unit and main memory
D) the arithmetic and logic unit (ALU) and main memory
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
27
Byte code instructions are
A) machine code instructions
B) syntax errors
C) read and interpreted by the JVM
D) another name for source code
A) machine code instructions
B) syntax errors
C) read and interpreted by the JVM
D) another name for source code
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
28
Application software refers to
A) the programs that make the computer useful to the user
B) the operating system
C) key words
D) pseudocode
A) the programs that make the computer useful to the user
B) the operating system
C) key words
D) pseudocode
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
29
One type of design tool used by programmers when creating a model of a program is
A) the ALU
B) byte code
C) syntax
D) pseudocode
A) the ALU
B) byte code
C) syntax
D) pseudocode
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
30
Which of the following is not part of the programming process?
A) defining and modeling the problem
B) entering code and compiling it
C) testing and debugging
D) All of these are parts of the programming process
A) defining and modeling the problem
B) entering code and compiling it
C) testing and debugging
D) All of these are parts of the programming process
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
31
A set of programming language statements that perform a specific task is a(n)
A) pseudocode chart
B) source code
C) object
D) procedure
A) pseudocode chart
B) source code
C) object
D) procedure
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
32
A runtime error is usually the result of
A) a logical error
B) a syntax error
C) a compiler error
D) bad data
A) a logical error
B) a syntax error
C) a compiler error
D) bad data
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
33
A characteristic of __________ is that only an object's methods are able to directly access and make changes to an object's data.
A) classes
B) procedures
C) data hiding
D) component reusability
A) classes
B) procedures
C) data hiding
D) component reusability
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
34
A computer program is
A) the same as main memory
B) only used for desktop computers
C) a set of instructions that allow the computer to solve a problem or perform a task
D) another name for an operating system
A) the same as main memory
B) only used for desktop computers
C) a set of instructions that allow the computer to solve a problem or perform a task
D) another name for an operating system
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
35
The data contained in an object is known as
A) the methods
B) the attributes
C) the classes
D) the fields
A) the methods
B) the attributes
C) the classes
D) the fields
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
36
Key words are
A) symbols or words that perform operations on one or more operands
B) words or characters representing values that are defined by the programmer
C) the data names in your program
D) words that have a special meaning in the programming language
A) symbols or words that perform operations on one or more operands
B) words or characters representing values that are defined by the programmer
C) the data names in your program
D) words that have a special meaning in the programming language
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
37
What is syntax?
A) the rules that must be followed when writing a program
B) the words that have a special meaning in the programming language
C) the symbols or words that perform operations in a program
D) the words or characters that are defined by the programmer
A) the rules that must be followed when writing a program
B) the words that have a special meaning in the programming language
C) the symbols or words that perform operations in a program
D) the words or characters that are defined by the programmer
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
38
There are __________ bits in a byte.
A) 4
B) 8
C) 16
D) 32
A) 4
B) 8
C) 16
D) 32
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
39
The original name for Java was
A) *7
B) Oak
C) HotJava
D) JavaScript
A) *7
B) Oak
C) HotJava
D) JavaScript
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck
40
A cross between human language and a programming language is called
A) a compiler
B) pseudocode
C) the Java Virtual Machine
D) the Java language
A) a compiler
B) pseudocode
C) the Java Virtual Machine
D) the Java language
Unlock Deck
Unlock for access to all 40 flashcards in this deck.
Unlock Deck
k this deck