Python Programming - Inheritance - Discussion

Discussion Forum : Inheritance - General Questions (Q.No. 49)
49.
How can you achieve method overloading in Python using variable-length arguments?
By using the @overload decorator
By explicitly specifying the data type of method parameters
By defining a method with *args or **kwargs
Method overloading is not possible in Python
Answer: Option
Explanation:
Method overloading in Python can be achieved by defining a method with variable-length arguments using *args or **kwargs.
Discussion:
Be the first person to comment on this question !

Post your comments here:

Your comments will be displayed after verification.