Cause all that matters here is passing the Oracle 1z0-808 exam. Cause all that you need is a high score of 1z0-808 Java SE 8 Programmer I exam. The only one thing you need to do is downloading Examcollection 1z0-808 exam study guides now. We will not let you down with our money-back guarantee.

2016 Sep 1z0-808 study guide

Q21. Given the code fragment: 


What is the result? 

A. Match 1 

B. Match 2 

C. No Match 

D. A NullPointerException is thrown at runtime. 

Answer: B 

Explanation: 

it will compare the string contents of the StringBuilder with string object. 


Q22. Given the following code: 


What is the output? 

A. 4 

B. 3 

C. 4 

D. 5 

E. 4 

F. 4 

21 

Answer: E 


Q23. Given the code fragment: 


Which option represents the state of the num array after successful completion of the outer loop? 


A. Option A 

B. Option B 

C. Option C 

D. Option D 

Answer: A 


Q24. Given: 


What is the result? 

A. 2 4 6 8 10 12 

B. 2 4 6 8 10 12 14 

C. Compilation fails 

D. The program prints multiple of 2 infinite times 

E. The program prints nothing 

Answer: B 


Q25. Given: 

public class Equal { 

public static void main(String[] args) { 

String str1 = "Java"; 

String[] str2 = {"J","a","v","a"}; 

String str3 = ""; 

for (String str : str2) { 

str3 = str3+str; 

boolean b1 = (str1 == str3); 

boolean b2 = (str1.equals(str3)); 

System.out.print(b1+", "+b2); 

What is the result? 

A. true, false 

B. false, true 

C. true, true 

D. false, false 

Answer: B 

Explanation: == strict equality. equals compare state, not identity. 


certifyforall.com

Refresh 1z0-808 practice:

Q26. Which of the following will print current time? 

A. System.out.print(new LocalTime()-now0); 

B. System.out.print(new LocalTime()); 

C. System.ouLprint(LocalTime.now()); 

D. System.ouLprint(LocalTime.today()); 

E. None of the above. 

Answer: C 

Explanation: 

The LocalTime is an interface, so we can't use new keyword with them. So options A and C are incorrect. To get current time we can call now method on LocalTime interface. So option C is correct. Option D is incorrect as there is no method called today as in LocalTime interface 

https://docs.oracle.com/javase/tutorial/datetime/iso/datetime.html 


Q27. Given: 


What is the result? 

A. Compilation fails 

B. The code compiles, but does not execute. 

C. Paildrome 

D. Wow 

E. Mom 

Answer: B 


Q28. Which two statements are true for a two-dimensional array? 

A. It is implemented as an array of the specified element type. 

B. Using a row by column convention, each row of a two-dimensional array must be of the same size. 

C. At declaration time, the number of elements of the array in each dimension must be specified. 

D. All methods of the class Object may be invoked on the two-dimensional array. 

Answer: A,D 


Q29. Given: 


What is the result? 

A. x: 1 y: 2 

B. 3 y: 4 

C. x: 0 y: 0 

D. 3 y: 4 

E. x: 1 y: 2 

F. 0 y: 0 

G. x: 0 y: 0 

H. 0 y: 0 

Answer: C 


Q30. Given the for loop construct: 

for ( expr1 ; expr2 ; expr3 ) { 

statement; 

Which two statements are true? 

A. This is not the only valid for loop construct; there exits another form of for loop constructor. 

B. The expression expr1 is optional. it initializes the loop and is evaluated once, as the loop begin. 

C. When expr2 evaluates to false, the loop terminates. It is evaluated only after each iteration through the loop. 

D. The expression expr3 must be present. It is evaluated after each iteration through the loop. 

Answer: B,C 

Explanation: 

The for statement have this forms: 

for (init-stmt; condition; next-stmt) { 

body 

There are three clauses in the for statement. 

The init-stmt statement is done before the loop is started, usually to initialize an iteration 

variable. 

The condition expression is tested before each time the loop is done. The loop isn't 

executed if the boolean expression is false (the same as the while loop). 

The next-stmt statement is done after the body is executed. It typically increments an 

iteration variable.