Oracle 1Z0-808

Page:    1 / 122   
Total 608 questions | Updated On: Apr 25, 2024
Question 1

Given the code fragment:

1Z0-808
What is the result?


Answer: C
Question 2

Examine the content of App.java:

1Z0-808
Which is true?


Answer: C
Question 3

Consider below code of Test.java file:

1. package com.sampleproject.oca;

2.  

3. class Super {

4.     public String num = "10"; //Line n1

5. }

6.  

7. class Sub extends Super {

8.     protected int num = 20; //Line n2

9. }

10.  

11. public class Test {

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

13.         Super obj = new Sub();

14.         System.out.println(obj.num += 2); //Line n3

15.     }

16. }

What will be the result of compiling and executing above code?


Answer: F
Question 4

Which of the following is a checked Exception?


Answer: D
Question 5

Given code of Thought.java file:

1. public class Thought {

2.     /*INSERT*/ {

3.         System.out.println("All is well");

4.     }

5. }

Which 3 options, if used to replace /*INSERT*/, will compile successfully and on execution will print "All is well" on to the console?


Answer: A,B,G
Page:    1 / 122   
Total 608 questions | Updated On: Apr 25, 2024

Quickly grab our 1Z0-808 product now and kickstart your exam preparation today!

Name: Java SE 8 Programmer I
Exam Code: 1Z0-808
Certification: Oracle Certified Associate
Vendor: Oracle
Total Questions: 608
Last Updated: Apr 25, 2024