00:00

QUESTION 1

Given:
1Z0-809 dumps exhibit
What is the result?

Correct Answer: D

QUESTION 2

Given the code fragment:
List empDetails = Arrays.asList(“100, Robin, HR”, “200, Mary, AdminServices”,
“101, Peter, HR”);
empDetails.stream()
.filter(s-> s.contains(“1”))
.sorted()
.f orEach(System.out::println); //line n1
What is the result?

Correct Answer: A

QUESTION 3

Given:
public class Canvas implements Drawable { public void draw () { }
}
public abstract class Board extends Canvas { }
public class Paper extends Canvas { protected void draw (int color) { }
}
public class Frame extends Canvas implements Drawable { public void resize () { }
}
public interface Drawable { public abstract void draw ();
}
Which statement is true?

Correct Answer: E

QUESTION 4

Given the code fragments:
class MyThread implements Runnable {
private static AtomicInteger count = new AtomicInteger (0); public void run () {
int x = count.incrementAndGet(); System.out.print (x+” “);
}
}
and
Thread thread1 = new Thread(new MyThread()); Thread thread2 = new Thread(new MyThread()); Thread thread3 = new Thread(new MyThread()); Thread [] ta = {thread1, thread2, thread3};
for (int x= 0; x < 3; x++) { ta[x].start();
}
Which statement is true?

Correct Answer: A

QUESTION 5

Given the content of /resourses/Message.properties: welcome1=”Good day!”
and given the code fragment: Properties prop = new Properties ();
FileInputStream fis = new FileInputStream (“/resources/Message.properties”); prop.load(fis);
System.out.println(prop.getProperty(“welcome1”)); System.out.println(prop.getProperty(“welcome2”, “Test”));//line n1 System.out.println(prop.getProperty(“welcome3”));
What is the result?

Correct Answer: C