Following example shows how super function is interpreted by ruby.
Output:
6
16
–
In this example we can see that super calls up the function of the base-class in which it is called.
Following example shows how super function is interpreted by ruby.
Output:
6
16
–
In this example we can see that super calls up the function of the base-class in which it is called.