Download Oracle.1z0-809.PracticeTest.2018-08-01.48q.tqb

Download Exam

File Info

Exam Java SE 8 Programmer II
Number 1z0-809
File Name Oracle.1z0-809.PracticeTest.2018-08-01.48q.tqb
Size 304 KB
Posted Aug 01, 2018
Download Oracle.1z0-809.PracticeTest.2018-08-01.48q.tqb

How to open VCEX & EXAM Files?

Files with VCEX & EXAM extensions can be opened by ProfExam Simulator.

Purchase

Coupon: MASTEREXAM
With discount: 20%






Demo Questions

Question 1

Given:
public class Foo<K, V>   { 
    private K key; 
    private V value; 
public Foo (K key, V value) (this.key = key; this value = value;) 
public static <T> Foo<T, T> twice (T value) (return new Foo<T, T> (value, value); ) 
public K getKey () (return key;) 
public V getValue () (return value;) 
Which option fails?


  1. Foo<String, Integer> mark = new Foo<String, Integer> (“Steve”, 100);); 
  2. Foo<String, String> pair = Foo.<String>twice (“Hello World!”);
  3. Foo percentage = new Foo(97, 32);
  4. Foo<String, String> grade = new Foo <> (“John”, “A”);
Correct answer: C



Question 2

Given the code fragment:
Stream<List<String>> iStr= Stream.of ( 
    Arrays.asList (“1”, “John”), 
    Arrays.asList (“2”, null)0; 
Stream<<String> nInSt = iStr.flatMapToInt ((x) -> x.stream ()); 
nInSt.forEach (System.out :: print);
What is the result? 


  1. 1John2null
  2. 12
  3. A NullPointerException is thrown at run time.
  4. A compilation error occurs.
Correct answer: D



Question 3

Given the code fragment:
Path file = Paths.get (“courses.txt”); 
// line n1 
Assume the courses.txt is accessible. 
Which code fragment can be inserted at line n1 to enable the code to print the content of the courses.txt file? 


  1. List<String> fc = Files.list(file);
    fc.stream().forEach (s - > System.out.println(s));
  2. Stream<String> fc = Files.readAllLines (file);
    fc.forEach (s - > System.out.println(s));
  3. List<String> fc = readAllLines(file);
    fc.stream().forEach (s - > System.out.println(s));
  4. Stream<String> fc = Files.lines (file);
    fc.forEach (s - > System.out.println(s));
Correct answer: D









CONNECT US

Facebook

Twitter

PROFEXAM WITH A 20% DISCOUNT

You can buy ProfExam with a 20% discount!



HOW TO OPEN VCEX FILES

Use ProfExam Simulator to open VCEX files