Multiple choice

What is the use of Super keyword in Java?

  1. Used for inheritance

  2. Allows child class to call parameterized constructor of the class

  3. Used for making a function inline

  4. Used for making class or function template

  5. Allows parent class to call parameterized constructor of child class

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

In constructor calling, default constructor of parent class gets automatically called. Super keyword allows child class to call parameterized constructor of the parent class.