Oracle Java SE 7 Programmer II - 1Z1-804 Exam Practice Test

Given: And the commands: javac Counter.java java ea Counter

What is the result?
Correct Answer: A
Explanation: Only visible for ExamsLabs members. You can sign-up / login (it's free).
Given:
StringBuffer b = new StringBuffer("3"); System.out.print(5+4+b+2+1);
What is the result?
Correct Answer: F
Explanation: Only visible for ExamsLabs members. You can sign-up / login (it's free).
Given:

What is the result?
Correct Answer: A
Explanation: Only visible for ExamsLabs members. You can sign-up / login (it's free).
Given the code fragment: Which two try statements, when inserted at line ***, enable you to print files with the extensions.java, .htm, and .jar.
Correct Answer: C,D
Explanation: Only visible for ExamsLabs members. You can sign-up / login (it's free).
Given:

Which of the four are valid modifications to synchronize access to the valid list between threads t1 and t2?
Correct Answer: A,B,E
Explanation: Only visible for ExamsLabs members. You can sign-up / login (it's free).
Given this code fragment:

Assume that the SQL query returns records.
What is the result?
Correct Answer: C
Given:

What is the most likely result?
Correct Answer: B
Given:

Which two classes correctly override the getDepth method?
Correct Answer: A,D
Explanation: Only visible for ExamsLabs members. You can sign-up / login (it's free).