Free Oracle 1Z0-809 Exam Questions

Absolute Free 1Z0-809 Exam Practice for Comprehensive Preparation 

  • Oracle 1Z0-809 Exam Questions
  • Provided By: Oracle
  • Exam: Java SE 8 Programmer II
  • Certification: Oracle Java
  • Total Questions: 469
  • Updated On: Dec 07, 2025
  • Rated: 4.9 |
  • Online Users: 938
Page No. 1 of 94
Add To Cart
  • Question 1
    • The last statement inside main(String []) method, increments value of i, which means it is not effectively final and hence compilation error.

      //Test.java

      package com.udayan.ocp;

       

      class Player {

          String name;

          int age;

          Player() {

              this.name = "Virat";

              this.age = 29;

          }

          

          public int hashCode() {

              return 100;

          }

      }

       

      public class Test {

          public static void main(String[] args) {

              System.out.println(new Player());

          }

      }

      Hexadecimal representation of 100 is 64.

      Which of the following option is correct?


      Answer: B
  • Question 2
    • Given:
      public class Counter {
       public static void main (String[ ] args) {
       int a = 10;
       int b = -1;
       assert (b >=1) : “Invalid Denominator”;
       int с = a / b;
       System.out.println (c);
       }
      }
      What is the result of running the code with the –da option?

      Answer: A
  • Question 3
    • Given code of Test.java file: 

      1. package com.udayan.ocp;

      2.  

      3. import java.util.Arrays;

      4. import java.util.List;

      5. import java.util.function.Predicate;

      6.  

      7. public class Test {

      8.     public static void main(String[] args) {

      9.         List list = Arrays.asList(-80, 100, -40, 25, 200);

      10.         Predicate predicate = num -> {

      11.             int ctr = 1;

      12.             boolean result = num > 0;

      13.             System.out.print(ctr++ + ".");

      14.             return result;

      15.         };

      16.         

      17.         list.stream().filter(predicate).findFirst();

      18.     }

      19. }

      What will be the result of compiling and executing Test class?


      Answer: D
  • Question 4
    • Given the code fragment:
      Untitled1-page69-image35
      What is the result?

      Answer: A
  • Question 5
    • What will be the result of compiling and executing class M?

      1. package com.udayan.ocp;

      2.  

      3. class M {

      4.     private int num1 = 100;

      5.     class N {

      6.         private int num2 = 200;

      7.     }

      8.     

      9.     public static void main(String[] args) {

      10.         M outer = new M();

      11.         M.N inner = outer.new N();

      12.         System.out.println(outer.num1 + inner.num2);

      13.     }

      14. }


      Answer: A
PAGE: 1 - 94
Add To Cart

© Copyrights DumpsEngine 2025. All Rights Reserved

We use cookies to ensure your best experience. So we hope you are happy to receive all cookies on the DumpsEngine.