Oracle 1Z0-852 Certification Sample Questions and Answers

1Z0-852 PDF, 1Z0-852 Dumps PDF Free Download, 1Z0-852 Dumps Free, 1Z0-852 Latest Dumps PDF, 1Z0-852 PDF Free DownloadThe Oracle 1Z0-852 Sample Question Set is designed to help you prepare for the Java SE 6 Programmer Certified Professional Upgrade (1Z0-852) certification exam. To become familiar with actual Oracle Certification exam environment, we suggest you to try Sample Oracle 1Z0-852 Certification Practice Exam.

This sample Oracle 1Z0-852 certification practice exam is designed for evaluation purposes only. If you really want to test your knowledge to identify your weak areas and familiarize with actual exam format, we suggest you to practice with Premium Oracle 1Z0-852 Certification Practice Exam for Java SE 6 Programmer Certified Professional Upgrade (1Z0-852) certification. Our team of Java experts have designed Questions-Answers for this premium practice exam by collecting inputs from recently certified candidates. Hence, We strongly recommend you to use Premium Oracle 1Z0-852 Certification Practice Exam to clear your actual Oracle 1Z0-852 Certification Exam with great score.

1Z0-852 Sample Questions:

01. Given the following six method names:
addListener addMouseListener setMouseListener deleteMouseListener removeMouseListener registerMouseListener
How many of these method names follow JavaBean Listener naming rules?
a) 1
b) 2
c) 3
d) 4
e) 5
02. Given that c is a reference to a valid object, which two code fragments read a line of text from the console?
(Choose two.)
a) String s = c.readLine();
b) char[] c = c.readLine();
c) String s = c.readConsole();
d) char[] c = c.readConsole();
e) String s = c.readLine("%s", "name ");
f) char[] c = c.readLine("%s", "name ");
03. Which can appropriately be thrown by a programmer using Java SE technology to create a desktop application?
a) ClassCastException
b) NullPointerException
c) NoClassDefFoundError
d) NumberFormatException
e) ArrayIndexOutOfBoundsException
04. Which three will compile and run without exception?
(Choose three.)
a) private synchronized Object o;
b) void go() {
synchronized() { /* code here */ }
c) public synchronized void go() { /* code here */ }
d) private synchronized(this) void go() { /* code here */ }
e) void go() {
synchronized(Object.class) { /* code here */ }
f) void go() {
Object o = new Object();
synchronized(o) { /* code here */ }
05. A programmer has an algorithm that requires a java.util.List that provides an efficient implementation of add(0, object), but does NOT need to support quick random access. What supports these requirements?
a) java.util.Queue
b) java.util.ArrayList
c) java.util.LinearList
d) java.util.LinkedList
06. Given a class whose instances, when found in a collection of objects, are sorted by using the compareTo() method, which two statements are true?
(Choose two.)
a) The class implements java.lang.Comparable.
b) The class implements java.util.Comparator.
c) The interface used to implement sorting allows this class to define only one sort sequence.
d) The interface used to implement sorting allows this class to define many different sort sequences.
07. Which two code fragments are most likely to cause a StackOverflowError?
(Choose two.)
a) int []x = {1,2,3,4,5}; for(int y = 0; y < 6; y++) System.out.println(x[y]);
b) static int[] x = {7,6,5,4}; static { x[1] = 8; x[4] = 3; }
c) for(int y = 10; y < 10; y++) doStuff(y);
d) void doOne(int x) { doTwo(x); } void doTwo(int y) { doThree(y); } void doThree(int z) { doTwo(z); }
e) for(int x = 0; x < 1000000000; x++) doStuff(x);
f) void counter(int i) { counter(++i); }
08. Which capability exists only in
a) Closing an open stream.
b) Flushing an open stream.
c) Writing to an open stream.
d) Writing a line separator to an open stream.
09. Which two scenarios are NOT safe to replace a StringBuffer object with a StringBuilder object?
(Choose two.)
a) When using versions of Java technology earlier than 5.0.
b) When sharing a StringBuffer among multiple threads.
c) When using the class StringBufferInputStream.
d) When you plan to reuse the StringBuffer to build more than one string.
10. Given that t1 is a reference to a live thread, which is true?
a) The Thread.sleep() method can take t1 as an argument.
b) The Object.notify() method can take t1 as an argument.
c) The Thread.yield() method can take t1 as an argument.
d) The Thread.setPriority() method can take t1 as an argument.
e) The Object.notify() method arbitrarily chooses which thread to notify.



Answer: b


Answer: a, e


Answer: d


Answer: c, e, f


Answer: d


Answer: a, c


Answer: d, f


Answer: d


Answer: a, b


Answer: e


Rating: 4.9 / 5 (43 votes)