Java OOP questions, please help, thanks 1. Consider the evaluation of the expres
ID: 3770568 • Letter: J
Question
Java OOP questions, please help, thanks
1.
Consider the evaluation of the expression (y >= z && a == b)
Which of the following is true?
y >= z is evaluated and then a == b is evaluated.
y >= z is evaluated and if true a == b is evaluated.
a == b is first evaluated and if it is false y >= z is skipped.
The order of evaluation is not deterministic.
2.
The == operator can be used to compare the values of two String objects and the result is true if the Strings contain the same characters in the same order.
True
False
3.
What is object serialization?
Placing a series of objects in an ordered array.
Converting an object into a stream of bytes in order to store or transmit the object.
Reading data from a network connection.
Using a thread to carry out a series of operations in the background.
4.
Which of the following methods is available on every object instance in Java?
equals()
println()
thread()
start()
getPackage()
5.
An instance of a thread can be started twice.
True
False
6.
Object-oriented programming allows you to derive new classes from existing classes. This is called ____________.
encapsulation
inheritance
abstraction
generalization
A.y >= z is evaluated and then a == b is evaluated.
B.y >= z is evaluated and if true a == b is evaluated.
C.a == b is first evaluated and if it is false y >= z is skipped.
D.The order of evaluation is not deterministic.
Explanation / Answer
1. B
2. False
3. B
4. A
5. False
6. B
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.