1Z0-816 Exam Details

  • Exam Code
    :1Z0-816
  • Exam Name
    :Java SE 11 Programmer II
  • Certification
    :Oracle Certifications
  • Vendor
    :Oracle
  • Total Questions
    :80 Q&As
  • Last Updated
    :Jun 26, 2026

Oracle 1Z0-816 Online Questions & Answers

  • Question 1:

    Given: Which two interfaces can be used in lambda expressions? (Choose two.)

    A. MyInterface1
    B. MyInterface3
    C. MyInterface5
    D. MyInterface2
    E. MyInterface4

  • Question 2:

    Given this enum declaration:

    Examine this code:

    System.out.println(Letter.values()[1]);

    What code should be written at line 5 for this code to print 200?

    A. public String toString() { return String.valueOf(ALPHA.v); }
    B. public String toString() { return String.valueOf(Letter.values()[1]); }
    C. public String toString() { return String.valueOf(v); }
    D. String toString() { return "200"; }

  • Question 3:

    Consider this method declaration:

    A) “SET SESSION AUTHORIZATION A. A, because it sends exactly the value of user provided by the calling code.
    B. B, because enquoting values provided by the calling code prevents SQL injection.
    C. A and B are functionally equivalent.
    D. A, because it is unnecessary to enclose identifiers in quotes.
    E. B, because all values provided by the calling code should be enquoted.

  • Question 4:

    A company has an existing sales application using a Java 8 jar file containing packages:

    com.company.customer; com.company.customer.orders; com.company.customer.info; com.company.sales; com.company.sales.leads; com.company.sales.closed; com.company.orders; com.company.orders.pending; com.company.orders.shipped.

    To modularize this jar file into three modules, customer, sales, and orders, which module-info.java would be correct?

    A. Option A
    B. Option B
    C. Option C
    D. Option D

  • Question 5:

    Given this enum declaration:

    Examine this code:

    System.out.println(Alphabet.getFirstLetter());

    What code should be written at line 3 to make this code print A?

    A. final String getFirstLetter() { return A.toString(); }
    B. static String getFirstLetter() { return Alphabet.values()[1].toString(); }
    C. static String getFirstLetter() { return A.toString(); }
    D. String getFirstLetter() { return A.toString(); }

  • Question 6:

    Examine these module declarations: Which two statements are correct? (Choose two.)

    A. The ServiceProvider module is the only module that, at run time, can provide the com.example.api API.
    B. The placement of the com.example.api API in a separate module, ServiceAPI, makes it easy to install multiple provider modules.
    C. The Consumer module should require the ServiceProvider module.
    D. The ServiceProvider module should export the com.myimpl package.
    E. The ServiceProvider module does not know the identity of a module (such as Consumer) that uses the com.example.api API.

  • Question 7:

    Which code fragment prints 100 random numbers?

    A. Option A
    B. Option B
    C. Option C
    D. Option D

  • Question 8:

    Which three guidelines are used to protect confidential information? (Choose three.)

    A. Limit access to objects holding confidential information.
    B. Clearly identify and label confidential information.
    C. Manage confidential and other information uniformly.
    D. Transparently handle information to improve diagnostics.
    E. Treat user input as normal information.
    F. Validate input before storing confidential information.
    G. Encapsulate confidential information.

  • Question 9:

    Given:

    You want to obtain the Stream object on reading the file. Which code inserted on line 1 will accomplish this?

    A. var lines = Files.lines(Paths.get(INPUT_FILE_NAME));
    B. Stream lines = Files.readAllLines(Paths.get(INPUT_FILE_NAME));
    C. var lines = Files.readAllLines(Paths.get(INPUT_FILE_NAME));
    D. Stream lines = Files.lines(INPUT_FILE_NAME);

  • Question 10:

    Which two are functional interfaces? (Choose two.)

    A. Option A
    B. Option B
    C. Option C
    D. Option D
    E. Option E

Tips on How to Prepare for the Exams

Nowadays, the certification exams become more and more important and required by more and more enterprises when applying for a job. But how to prepare for the exam effectively? How to prepare for the exam in a short time with less efforts? How to get a ideal result and how to find the most reliable resources? Here on Vcedump.com, you will find all the answers. Vcedump.com provide not only Oracle exam questions, answers and explanations but also complete assistance on your exam preparation and certification application. If you are confused on your 1Z0-816 exam preparations and Oracle certification application, do not hesitate to visit our Vcedump.com to find your solutions here.