The super keyword is a reference variable that is used to refer immediate parent class object. Whenever we create the instance of subclass, an instance of parent class is created implicitly i.e. referred by super reference variable.
Usage of java super Keyword
1. super is used to refer immediate parent class instance variable.
2. super can be used to invoke parent class constructor.
3. super can be used to invoke parent class method
The super keyword can also be used to invoke parent class method.
1. super() is added in each class constructor automatically by compiler.
super() is provided by the compiler implicitly:
2. No need of super keyword to call parent class method:
If there is no method in subclass as parent, there is no need to use super.