nerdexam
Oracle

1Z0-851 · Question #271

Click the Exhibit button. Given: ClassA a = new ClassA(); a.methodA(); What is the result?

The correct answer is D. An exception is thrown at runtime. See the full explanation below for the reasoning.

Question

Click the Exhibit button. Given: ClassA a = new ClassA(); a.methodA(); What is the result?

Exhibit

1Z0-851 question #271 exhibit

Options

  • ACompilation fails.
  • BClassC is displayed.
  • CThe code runs with no output.
  • DAn exception is thrown at runtime.

How the community answered

(33 responses)
  • A
    6% (2)
  • B
    3% (1)
  • C
    18% (6)
  • D
    73% (24)

Community Discussion

No community discussion yet for this question.

Full 1Z0-851 Practice