You have just seen that overloading is essentially a trick with names, effectively treating the argument list as part of the method identification. Overriding is somewhat more subtle, relating directly to subclassing and hence to the object-oriented nature of a language. When you extend one class to produce a new one, you inherit and have access to all the non-private methods of the original class. Sometimes, however, you might need to modify the behavior of one of these methods to suit your new class. In this case, you actually want to redefine the method, and this is the essential purpose of overriding.
Overloaded methods can exist, in any number, in the same class.
Each method in a parent class can be overridden at most once in any one subclass. Overloading allows multiple implementations of the same essential functionality to use the same name. Overriding, on the other hand, modifies the implementation of a particular piece of behavior for a subclass. Consider a class that describes a rectangle. Imaginatively, we'll call it Rectangle .