1.

What would be the behaviour if this() and super() used in a method?(a) Runtime error(b) Throws exception(c) compile time error(d) Runs successfully

Answer» Right answer is (c) compile time error

The explanation: this() and super() cannot be used in a method. This throws compile time error.


Discussion

No Comment Found

Related InterviewSolutions