Pass4itsure > Oracle > Oracle Certifications > 1Z0-811 > 1Z0-811 Online Practice Questions and Answers

1Z0-811 Online Practice Questions and Answers

Questions 4

Which statement is true about primitive variables?

A. They can be compared with the == operator.

B. They can be compared with the equals method only.

C. They cannot be compared.

D. They can be compared with the compareTo method only.

Buy Now
Questions 5

Given the code fragment:

What is the result?

A. 2

B. 4

C. The program executes an infinite number of times.

D. 3

Buy Now
Questions 6

Identify two Java reserved words.

A. array

B. true

C. this

D. exception

E. string

Buy Now
Questions 7

Given the code fragment:

What is the result?

A. pen pencil erasers paper

B. paper pen pencil erasers

C. A compilation error occurs.

D. A runtime exception is thrown.

Buy Now
Questions 8

Given the code fragment:

Which code fragment can be inserted at line n1 to enable the code to print 0.0?

A. Ball b = null;

B. weight = 0.0;

C. Ball.weight = 0.0;

D. Ball b = new Ball(0.0);

E. Ball b = new Ball();

Buy Now
Questions 9

Which two statements are true about the Java Runtime Environment (JRE)?

A. It is responsible for garbage collection.

B. It interprets bytecode stored in a .class file.

C. It contains the JDK and Java APIs.

D. It is platform independent.

E. You must install the JRE to compile a .java file.

Buy Now
Questions 10

Given the code fragment:

What is the result?

A. Unknown issues. Invalid divisor.

B. Unknown issues.

C. Invalid divisor.

D. A compilation error occurs.

Buy Now
Questions 11

Given:

What is the result?

A. A compilation error occurs in the modify method.

B. 99

C. 5

D. A compilation error occurs in the main method.

Buy Now
Questions 12

Given the code fragment:

What is the result?

A. A compilation error occurs at line n1.

B. Jack

C. The program prints either Jack or Queen.

D. Queen

Buy Now
Questions 13

Given:

What is the result?

A. The program compiles and nothing is printed.

B. Iteration plus an increasing number is printed 100 times.

C. Iteration plus an increasing number is printed 99 times.

D. An error occurs during compilation.

Buy Now
Exam Code: 1Z0-811
Exam Name: Java Foundations
Last Update: Jan 18, 2025
Questions: 75
10%OFF Coupon Code: SAVE10

PDF (Q&A)

$49.99

VCE

$55.99

PDF + VCE

$65.99