-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlab109.py
More file actions
29 lines (25 loc) · 736 Bytes
/
lab109.py
File metadata and controls
29 lines (25 loc) · 736 Bytes
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
print('Python has three numerical types: int, float and complex')
#Int data types
myvalue=1
print(myvalue)
print(type(myvalue))
print(str(myvalue) + ' is of the data type ' + str(type(myvalue)))
#Float data types
myvalue2=3.14
print(myvalue2)
print(type(myvalue2))
print(str(myvalue2) + ' is of the data type ' + str(type(myvalue2)))
#Complex data types
myvalue3=5j
print(myvalue3)
print(type(myvalue3))
print(str(myvalue3) + ' is of the datatype ' + str(type(myvalue3)))
#Boolean data types
myvalue4=True
print(myvalue4)
print(type(myvalue4))
print(str(myvalue4) + ' is of the datatype ' + str(type(myvalue4)))
myvalue5=False
print(myvalue5)
print(type(myvalue5))
print(str(myvalue5) + ' is of the datatype ' + str(type(myvalue5)))