stud
bud
Sign up
Log in
Home
Library
Explore
SAT
More
Duplicate of Intro Java - Chapter 1 - 4 Review Flashcards | StudBud
Explore
/
Duplicate of Intro Java - Chapter 1 - 4 Review
Duplicate of Intro Java - Chapter 1 - 4 Review
50 terms
·
StudBud Administration
A #Java quiz to review basic object-oriented programming concepts with students.
Flashcards
50 cards
F
Practice quiz
P
Host live
L
Questions
50
Answers
1
What is the syntax for calling the println method on the object System.out?
System.out.println ("Any message");
Println(System.out, "any message");
System.out("Any message").println;
Println("any message").system.out
2
What is the process of hiding object date and providing methods for data access called?
documentation
abstraction
encapsulation
instantiation
3
What is the length of the string "Java Program"?
none of these
12
11
14
4
The output of a method is called its ________________ value.
Explicit
Implicit
Return
Parameter
5
What is the output of the following Java statement?
46
4
10
4+6
6
A single letter, symbol, or digit is called a
Character
Symbol
Cartoon
Type
7
@param denotes what type of variable?
constant
instance variable
return variable
parameter variable
8
Information provided to the program to make it run correctly:
Instance
Override
Output
Input
9
Private instance variables _____________________
cannot be accessed by methods of the same class
can only be accessed by the constructor of the class
can only be accessed by methods of a different class
can only be accessed by methods of the same class
10
A ____________ is a collection of classes with a related purpose.
collection
package
method
import
11
What does an object store its data in?
methods
access specifiers
instance variables
files
12
To use a class in another package you need to __________________ it.
import
rewrite
export
overload
13
What is the return type of a constructor?
private
A constructor does not have a return type.
void
public
14
Standard code assigned values consisting of two bytes to characters used in text around world:
Universal Code
Translation
Bytecode
Unicode
15
Collection of code - programmed & translated by someone else - ready for use in your programs
Parameter
Method
Class
Library
16
To increase or add to a value is to:
Deflate
Decrement
Increment
Inflate
17
Encapsulation allows a programmer to use a class without having to know its________________.
implementation
interface
methods
name
18
The rule that defines which operator is evaluated first is called:
Murphy's Law
Rule of Law
Order of Operations
Robert's Rules of Order
19
A value that cannot be changed by a program is called a:
constant
magic number
static number
final
20
Which statement best describes the portability characteristic of Java?
same Java class files run on different OSs without change
Easy to compile Java source code one different OSs
easy to copy Java source code from one machine to another
Easy to change a program so it'll work on different OSs
21
What term is used to refer to text in a program that helps human readers understand the program
Statement
Methods
Comments
Constants
22
Symbols that indicate a mathematical or logical operation
Operators
Expressions
Constructors
Math
23
What translates Java source code into files that contain instructions from the JVM?
Compiler
Assembler
Linker
Interpreter
24
Information about each class is the Java library is found in the:
JPI Documentation
Appendix
API Documentation
Code Hints
25
What does CPU stand for?
Central Programming Unit
Computer Processing unit
Central Processing Unit
Computer Programming Unit
26
Each object of a class has its own set of ____________________.
instance variables
classes
methods
constructors
27
A string that tells the user what information to provide is called a:
Prompt
Output
Poke
Input
28
Information that is given to the user by the program is called:
Cast
Input
Output
Prompt
29
In Java, every statement must end with this symbol.
;
!
}
.
30
What is the term used to refer to Java code that runs in a browser?
Script
Html
Applet
Class
31
Which terminology describes a method that modifies the internal data of its implicit parameter?
public
void
accessor
mutator
32
Converting a value from one type to a different type is called:
Fishing
Casting
Basting
Changing
33
What term is used to refer to a sequence of characters enclosed in quotation marks?
Object
Comment
String
Variable
34
The name of the constructor is always the same as the name of the _______________________.
parameter variable
class
instance variable
access specifier
35
A reserved word used to declare and define constants is:
Char
Final
Static
Void
36
Setting a variable's initial value is called:
Inferrence
Initialization
Instance
Instantiation
37
To place one string after another to create a new string; adding strings together:
Addition
Combine
Merge
Concatenate
38
Every Java program consists of one or more of these fundamental building blocks.
Parameter
CPU
Applet
Class
39
Error caused because the computer will only store a specific number of digits-no rounding.
Computation Error
Round Off Errors
Compile Error
Run-time Error
40
You should declare all instance variables as _______________.
protected
class
private
public
41
By convention, classes begin with a(n)
Digit
Lowercase letter
Dollar sign
Uppercase letter
42
What is the name of the constructor for the
BankAccount
class?
withdraw
deposit
BankAccount
balance
43
Which statement best describes a computer program?
a sequence of comments
decides what task it is to perform
a program can only perform one simple task
sequence of instructions/decisions the computer carries out
44
A ____ contains sequences of instructions to perform a particular task.
Variable
Label
Method
Parameter
45
What type of program can you use to enter your Java program?
Database
Editor
Spreadsheet
Compiler
46
When a Java application starts, what is the name of the method that is executed?
begin
main
Main
start
47
What is the name of the file declaring the class named MyClass?
MyClass
MyClass.java
MyClass.class
myclass.java
48
A data type that can contain any number of characters is called:
String
Text
Digit
Char
49
Parameters to methods are enclosed by these symbols.
**
//
{}
()
50
What statement is used to specify the valuet that method gives back to is caller?
return
private
public
new