Oracle
1Z0-804 · Question #10
Given: What is the result?
The correct answer is D. Compilation fails. Exception in thread "main" java.lang.ExceptionInInitializerError at garden.Garden.main Caused by: java.lang.RuntimeException: Uncompilable source code - garden.Plant is not abstract and doesnot override abstract method growthDirection() in garden.Plant
RAC Architecture
Question
Given:
What is the result?
Exhibit
Options
- AUp Down
- BUp Up
- CUp null
- DCompilation fails
- EAn exception is thrown at runtime
How the community answered
(19 responses)- A5% (1)
- B11% (2)
- C5% (1)
- D79% (15)
Explanation
Exception in thread "main" java.lang.ExceptionInInitializerError at garden.Garden.main Caused by: java.lang.RuntimeException: Uncompilable source code - garden.Plant is not abstract and doesnot override abstract method growthDirection() in garden.Plant
Topics
#Java inheritance#method overriding#compilation failure#static vs instance
Community Discussion
No community discussion yet for this question.
