nerdexam
Oracle

1Z0-804 · Question #4

Given: What is the result?

The correct answer is C. compilation fails. public String ride() { return "cantering "; } public String ride() { return "tolting "; } if this is given then the result would be: A : tolting cantering tolting

RAC Architecture

Question

Given:

What is the result?

Exhibit

1Z0-804 question #4 exhibit

Options

  • Atolting cantering tolting
  • Bcantering cantering cantering
  • Ccompilation fails
  • Dan exception is thrown at runtime

How the community answered

(15 responses)
  • A
    13% (2)
  • B
    7% (1)
  • C
    73% (11)
  • D
    7% (1)

Explanation

public String ride() { return "cantering "; } public String ride() { return "tolting "; } if this is given then the result would be: A : tolting cantering tolting

Topics

#Java method overriding#inheritance#compilation failure#polymorphism

Community Discussion

No community discussion yet for this question.

Full 1Z0-804 Practice