-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path10_function.py
53 lines (44 loc) · 1.19 KB
/
10_function.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# defining a function
#1
# def print_pinki():
# print("learnin python of python with me")
# print("learnin python of python with me")
# print("learnin python of python with me")
# print_pinki()
#2
# def print_pinki():
# text ="learning of python with me in vs code which is best"
# print(text)
# print(text)
# print(text)
# print_pinki()
#3
# def print_pinki(text):
# print(text)
# print(text)
# print(text)
# print(text)
# print_pinki("lening of python with me in vs code which is best")
#defining a function with if ,elif and else statements
# def school_calculater(age, text):
# if age==5:
# print("hammad can go to shool")
# elif age>5:
# print("hammad should go to higher school ")
# else:
# print(": hammad can not go to school")
# school_calculater(3,"hammad")
#
# def school_calculater(age):
# if age==5:
# print("hammad can go to shool")
# elif age>5:
# print("hammad should go to higher school ")
# else:
# print(": hammad can not go to school")
# school_calculater(3)
# defining a function of future
def future_age(age):
new_age=age+20
print(new_age)
future_age(10)