1Z0-803 | how many questions of 1Z0-803 dumps?


Q71. Why will the code not compile? 

A. A static field cannot be private. 

B. The getLetter method has no body. 

C. There is no setLetter method. 

D. The letter field is uninitialized. 

E. It contains a method named Main instead of ma 

Answer:

Q72. Given: 

What is true about the class Wow? 

A. It compiles without error. 

B. It does not compile because an abstract class cannot have private methods. 

C. It does not compile because an abstract class cannot have instance variables. 

D. It does not compile because an abstract class must have at least one abstract method. 

E. It does not compile because an abstract class must have a constructor with no arguments. 

Answer:

Q73. What is the result? 

A. 6 7 8 

B. 7 8 9 

C. 0 1 2 

D. 6 8 10 

E. Compilation fails 

Answer:

Q74. which three lines are illegal? 

A. line 3 

B. line 4 

C. line 5 

D. line 6 

E. line 10 

F. line 11 

G. line 12 

H. line 13 

Answer: CDH 

Q75. Which statement initializes a stringBuilder to a capacity of 128? 

A. StringBuilder sb = new String ("128"); 

B. StringBuilder sb = StringBuilder.setCapacity (128); 

C. StringBuilder sb = StringBuilder.getInstance (128); 

D. StringBuilder sb = new StringBuilder (128); 

Answer:

Q76. public class MyFor { 

public static void main(String[] args) { 

for (int ii = 0; ii < 4; ii++) { 

System.out.println("ii = "+ ii); 

ii = ii +1; 

What is the result? 

A. ii = 0 

ii = 2 

B. ii = 0 

ii = 1 

ii = 2 

ii = 3 

C. ii = 

D. Compilation fails. 

Answer:

Q77. Given the code fragment:

A. 20 

B. 25 

C. 29 

D. Compilation fails 

E. An Array Index Out Of Bounds Exception is thrown at runtime 

Answer:

Q78. Given: 

Class A { } 

Class B { } 

Interface X { } 

Interface Y { } 

Which two definitions of class C are valid? 

A. Class C extends A implements X { } 

B. Class C implements Y extends B { } 

C. Class C extends A, B { } 

D. Class C implements X, Y extends B { } 

E. Class C extends B implements X, Y { } 

Answer: AE 

Q79. Given: 

What is the result? 

A. 7 

B. 12 

C. 19 

D. Compilation fails 

E. An exception is thrown at run time 

Answer:

Q80. Given the code fragment: 

interface SampleClosable { 

public void close () throws java.io.IOException; 

Which three implementations are valid? 

A. Option A 

B. Option B 

C. Option C 

D. Option D 

E. Option E 

Answer: ACE