OOP
OOP
Inheritance
“is-a” relationship
Single inheritance:
Subclass is derived from one existing class
(superclass)
Multiple inheritance:
Subclass is derived from more than one superclass
Not supported by Java
A class can only extend the definition of one class
• Add( ) ; // No arguments
The statement
I 2 = I 1;
will not invoke the copy constructor.