Python Programming - Inheritance - Discussion

Discussion Forum : Inheritance - General Questions (Q.No. 66)
66.
How can you achieve method overloading?
By declaring methods with different return types
By defining multiple methods with the same name but different parameters
By explicitly specifying the data type of method parameters
Method overloading is not supported in Python
Answer: Option
Explanation:
Python does not support method overloading in the traditional sense as it is done in languages like Java. Methods with the same name in a class will override each other.
Discussion:
Be the first person to comment on this question !

Post your comments here:

Your comments will be displayed after verification.