SUBJECTS
|
BROWSE
|
CAREER CENTER
|
POPULAR
|
JOIN
|
LOGIN
Business Skills
|
Soft Skills
|
Basic Literacy
|
Certifications
About
|
Help
|
Privacy
|
Terms
|
Email
Search
Test your basic knowledge |
Object Oriented Programming
Start Test
Study First
Subject
:
it-skills
Instructions:
Answer 50 questions in 15 minutes.
If you are not ready to take this test, you can
study here
.
Match each statement with the correct term.
Don't refresh. All questions and answers are randomly picked and ordered every time you load a test.
This is a study tool. The 3 wrong answers for each question are randomly chosen from answers to other questions. So, you might find at times the answers obvious, but you will see it re-enforces your understanding as you take the test each time.
1. Provides read-only access to a particular value - e.g. getX where X is the value to which it provides access.
Scanner scan=new Scanner (System.in);
assignment
accessor method
method
2. Provides generic formatting capabilities for numbers; you don't instantiate a NumberFormat object by using the "new" operator.
NumberFormat class
instance data
local data
java.util class libary
3. In the header of a method specifies he types of the values that are passed and the names by which the called method will refer to those values.
string name;
method declaration
parameter list
tokens
4. Returns the next input token as the indicated type.
escape sequences
byte nextByte( )
literal
Scanner class
5. Returns all input remaining on the current line as a character string.
higher
method
String nextLine( )
attributes of an object
6. Methods in the Math class are ______
encapsulation
a constructor
dot operator
static
7. A ________________ is immutable.
arithmetic
num=Integer.parseInt(str);
String object
delimiters
8. Returns a new string identical to this string except all uppercase letters are converted to their lowercase equivalent.
String format (double number)
instantiation
String toLowerCase ( )
char charAt (int index)
9. Eight primitive data types: four subsets of integers - two subsets of ________ - a character data type - and a boolean data type
byte nextByte( )
Scanner useDelimiter(String pattern)
floating point numbers
String replace (char oldChar - char newChar)
10. A method that returns a value must have a _________
class
return statement
String toUpperCase ( )
attributes of an object
11. Declared in a class but not inside any particular method
java.util class libary
String concat (String str)
instance data
declared
12. A class usually provides services to access and modify __________
String next( )
boolean equalsIgnoreCase (String str)
RH
data values
13. Provide various methods related to the management of the associated primitive type. Used when we create an object that serves as a container to hold various types of other objects - and we want the object to hold a simple integer value. In this case
method
character literal
wrapper class
java.lang package
14. We use an object when we have a _________ to it
reference
instance data
service methods
have void
15. The one that is invoked
called method
uninitialized variables
byte nextByte( )
parameter
16. Behaviors associated with a bank account (which include the ability to make deposits and withdrawals)
initialize
byte to short
instantiation
behaviors of an object
17. Even though a method may not take parameters - _________ are still necessary to indicate that a method is being invoked
java.lang package
parentheses
int compareTo (String str)
enumerated type
18. This declaration creates a Scanner object that reads input from the keyboard
the DecimalFormat class
polymorphism
underscores
Scanner scan=new Scanner (System.in);
19. A value that is passed into a method when it is invoked
parameter
tokens
aliases
String findInLine (String pattern)
20. The values it stores internally - which may be represented as primitive data or as other objects. for example - a bank account object can store a floating point number (a primitive value) that represents the balance of the account. it can also contai
int length( )
pointer
attributes of an object
long
21. _____ expression evaluated first
uninitialized variables
encapsulation of an object
RH
return statement
22. Returns a new string identical to this string except all lowercase letters are converted to their uppercase equivalent.
the "import" declaration
String toUpperCase ( )
byte to short
underscores
23. All wrapper classes are defined in ___________
not possible
actual parameters
String replace (char oldChar - char newChar)
java.lang package
24. A special method that has the same name as the class. After the "new" operator creates the object it is invoked to help set it up initially
a constructor
scope
class level
int length( )
25. Return type specified in the method header can be a primitive type - class name or the ________; when a method does not return any value - void is used as the return type - as is always done with the main method.
service methods
reserved word void
character literal
accessor method
26. The location at which a variable is declared defines its scope - which is the area within a program in which the variable can be referenced.
constants
Understanding
scope
uninitialized variables
27. Returns a new string that is identical with this string except that every occurrence of oldChar is replaed by newChar
String replace (char oldChar - char newChar)
flow of control
class level
int length( )
28. Sets the scanner's delimiting pattern.
autoboxing
the "import" declaration
Scanner useDelimiter(String pattern)
Random class
29. Specifies the packages and classes that will be used in a program so that the fully qualified name is not necessary with each reference.
the "import" declaration
instantiation
character literal
underscores
30. They clarify the role a certain number has in the program.
method invocation
constants
not possible
formal parameters
31. Returns the next input token as the indicated type.
character literal
variable
boolean nextBoolean( )
wrapper class
32. Protection and management of an object's info. this implies that the object should be self-governing. the only changes made to the state of the object should be accomplished by that object's methods. other objects should not be able to "reach in" to
encapsulation of an object
int compareTo (String str)
mutator method
instantiation
33. Two categories of statements that control the flow of executing through a method: __________ and loops
null
conditionals
header of a method
parentheses
34. Count++; count--
attributes of an object
Scanner scan=new Scanner (System.in);
postfix form
instance data
35. A Java operator that is specified by a type name in parentheses; truncates rather than rounds; useful in division if u want an integer to be treated as a float or double
casting
delimiters
Random ( )
variable name
36. The automatic conversion between a primitive value and a corresponding wrapper object.
Scanner useDelimiter(String pattern)
autoboxing
variable
parameter
37. Part of the standard Java class library - provides convenient methods for reading input values of various types. the input can come from various sources - including data typed interactively by the user or data stored in a file; the Scanner class can
operations
class library
String findInLine (String pattern)
Scanner class
38. Occurs automatically when certain operators need to modify their opeands in order to perform the operation
String toUpperCase ( )
instance data
String toLowerCase ( )
promotion
39. The declarations of object variables have a similar structure to the declaration of _______________
instance data
instantiation
primitive variables
local data
40. Returns the next input token as a character string.
String concat (String str)
arithmetic
parentheses
String next( )
41. How classes are created from other classes. the definition of one class can be based on another class that already exists. inheritance is a form of software reuse - capitalizing on the similarities between various kinds of classes that we want to cre
set
variable name
inheritance
assignment
42. Expressed in a Java program with single quotes
promotion
RH
character literal
java.lang package
43. declaration that creates a String variable that holds a reference to a String object; an object variable doesn't hold an object itself - it holds the address of an object
scope
character string
assignment statement
string name;
44. A variable that refers to an object must be __________
Random class
parameter list
initialize
declared
45. Boolean type conversions are ___________
casting
not possible
constructors
actual parameters
46. System.out object represents an output device or file; we send the println message to the System.out object to request that some text be printed
System.out.println
prefix form
actual parameters
class
47. A name for a location in memory used to hold a data value.
String findInLine (String pattern)
variable
character literal
null
48. sides=10;
conditionals
accessor method
assignment statement
instance variable
49. New memory space is reserved for that variable every time an instance of the class that is created.
a constructor
double
instance data
formal parameters
50. An object has behaviors - which are defined by the ________ associated with that object.
self-governing
operations
postfix form
underscores
Can you answer 50 questions in 15 minutes?
Let me suggest you:
Browse all subjects
Browse all tests
Most popular tests
Major Subjects
Tests & Exams
AP
CLEP
DSST
GRE
SAT
GMAT
Certifications
CISSP go to https://www.isc2.org/
PMP
ITIL
RHCE
MCTS
More...
IT Skills
Android Programming
Data Modeling
Objective C Programming
Basic Python Programming
Adobe Illustrator
More...
Business Skills
Advertising Techniques
Business Accounting Basics
Business Strategy
Human Resource Management
Marketing Basics
More...
Soft Skills
Body Language
People Skills
Public Speaking
Persuasion
Job Hunting And Resumes
More...
Vocabulary
GRE Vocab
SAT Vocab
TOEFL Essential Vocab
Basic English Words For All
Global Words You Should Know
Business English
More...
Languages
AP German Vocab
AP Latin Vocab
SAT Subject Test: French
Italian Survival
Norwegian Survival
More...
Engineering
Audio Engineering
Computer Science Engineering
Aerospace Engineering
Chemical Engineering
Structural Engineering
More...
Health Sciences
Basic Nursing Skills
Health Science Language Fundamentals
Veterinary Technology Medical Language
Cardiology
Clinical Surgery
More...
English
Grammar Fundamentals
Literary And Rhetorical Vocab
Elements Of Style Vocab
Introduction To English Major
Complete Advanced Sentences
Literature
Homonyms
More...
Math
Algebra Formulas
Basic Arithmetic: Measurements
Metric Conversions
Geometric Properties
Important Math Facts
Number Sense Vocab
Business Math
More...
Other Major Subjects
Science
Economics
History
Law
Performing-arts
Cooking
Logic & Reasoning
Trivia
Browse all subjects
Browse all tests
Most popular tests