English

State whether the following is function overloading or not. Explain why or why not. def (a,b): def(x,y) :

Advertisements
Advertisements

Question

State whether the following is function overloading or not. Explain why or why not.

def (a,b):
def(x,y) :

Explain
Advertisements

Solution

Not function overloading.

Both functions have the same function signature because each has two parameters. Changing only parameter names from (a, b) to (x, y) does not create an overloaded function.

shaalaa.com
  Is there an error in this question or solution?
Chapter 2: Concept of Object Oriented Programming - EXCERCISE [Page 38]

APPEARS IN

CBSE Computer Science with Python [English] Class 12
Chapter 2 Concept of Object Oriented Programming
EXCERCISE | Q 14. a. | Page 38
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×