Function & docstring

e=4
f=5
c=sum((e,f))#built in function
print(c)

def function1(a,b):

print("now iam in function",a+b)
function1(5,10)

def function2(c,d):
"""this is a function which will calculate average of two no"""

average=(c+d)/2
#print (average)
return average

'''v=function2(10,20)

print(v)'''

print (function2.__doc__)


Comments

Popular posts from this blog

Steps taken by a compiler to execute a C program

Tokens in C

Variables and Data Types in C