Super is a keyword in java language which is used in two different ways.
- super. :
super.(dot) is used to differentiate parent class variables and child class variables whenever both are same name.
super . always represents parent class variable.
super() is used to call the parent class constructor within derived class constructor.
super() always first statement of the constructor.
class Child extends Parent
super(20); -->First statement of the constructor.