- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvariable.py
More file actions
Latest commit
23 lines (14 loc) · 625 Bytes
/
Copy pathvariable.py
File metadata and controls
23 lines (14 loc) · 625 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#dynamic typing: type of variable is determined at runtime or Variable can point to objects of any data type
age_list= [34, 25, 23, 19, 29]
max_age=max(age_list)
print(f'maximum age value: {max_age}')
min_age=min(age_list)
print(f'the difference between max age and min age is {max_age-min_age}')
# change the type of max_age variable from integer to string
max_age=str(max_age)
print(f'converted type of the variable: {type(max_age)}')
# reassign the total new value to the variable, reassign
max_age="ninety-nine"
print(max_age)
# python follow the order of paranthesis in mathematics
print(2+ (3*4))