Exam Code: 1Z0-808
Exam Questions: 608
Java SE 8 Programmer I
Updated: 06 Jan, 2026
Viewing Page : 1 - 61
Practicing : 1 - 5 of 608 Questions
Question 1

What will be the result of compiling and executing Test class?package com.udayan.oca; import java.util.ArrayList;import java.util.List; public class Test {     public static void main(String[] args) {         List list = new ArrayList();         list.add(100);         list.add(7);         list.add(50);         list.add(17);         list.add(10);         list.add(5);          list.removeIf(a -> a % 10 == 0);          System.out.println(list);     }}

Options :
Answer: A

Question 2

Given code of Test.java file:1. package com.sampleproject.oca;2.  3. abstract class Animal {4.     abstract void jump() throws RuntimeException;5. }6.  7. class Deer extends Animal {8.     void jump() { //Line n19.         System.out.println("DEER JUMPS");10.     }11.  12.     void jump(int i) {13.         System.out.println("DEER JUMPS TO " + i + " FEET");14.     }15. }16.  17. public class Test {18.     public static void main(String[] args) {19.         Animal animal = new Deer();20.         ((Deer)animal).jump(); //Line n221.         ((Deer)animal).jump(5); //Line n322.     }23. }What will be the result of compiling and executing Test class?

Options :
Answer: A

Question 3

Given:1Z0-808What is the result?

Options :
Answer: D

Question 4

Given the code fragment:HPE6-A70Which two modifications, when made independently, enable the code to print joe:true: 100.0? (Choose two.)

Options :
Answer: A,C

Question 5

How many String objects are there in the HEAP memory, when control is at Line 9?1. package com.udayan.oca;2.  3. public class Test {4.      public static void main(String[] args) {5.          String s1 = new String("Java"); //Line 36.          String s2 = "JaVa"; //Line 47.          String s3 = "JaVa"; //Line 58.          String s4 = "Java"; //Line 69.          String s5 = "Java"; //Line 710.  11.          int i = 1; //Line 912.  13.      }14. }

Options :
Answer: B

Viewing Page : 1 - 61
Practicing : 1 - 5 of 608 Questions

© Copyrights FreePDFQuestions 2026. All Rights Reserved

We use cookies to ensure that we give you the best experience on our website (FreePDFQuestions). If you continue without changing your settings, we'll assume that you are happy to receive all cookies on the FreePDFQuestions.