nerdexam
Oracle

1Z0-851 · Question #151

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 #151 exhibit

Options

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

How the community answered

(23 responses)
  • A
    13% (3)
  • B
    9% (2)
  • C
    4% (1)
  • D
    74% (17)

Community Discussion

No community discussion yet for this question.

Full 1Z0-851 Practice