-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnumeric-data.py
More file actions
68 lines (47 loc) · 1.99 KB
/
Copy pathnumeric-data.py
File metadata and controls
68 lines (47 loc) · 1.99 KB
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
#Se realizan operaciones basicas imprimiendo directamente a consola
print(2+2)
print(4-2)
print(2*2)
print(4/2)
#Imprimimos un texto plano
print("Python has three numeric types: int, float, and complex")
#Creamor una variable llamada myValue y guardamos el valor de 1
myValue = 1
#Imprimimos el valor de la variable myValue
print(myValue)
#Para saber el tipo de una variable usamos type
print(type(myValue))
#Cuando usamos la funcion str() vamos a imprimirel valor de la variable como si fuera texto
print(str(myValue) + "is of the data type" + str(type(myValue)))
#Las variables en Py pueden cambiar los valores que les damos
myValue = 3.14
#Imprimimos el valor de la variable myValue
print(myValue)
#Para saber el tipo de una variable usamos type
print(type(myValue))
#Cuando usamos la funcion str() vamos a imprimirel valor de la variable como si fuera texto
print(str(myValue) + "is of the data type" + str(type(myValue)))
#Las variables en Py pueden cambiar los valores que les damos
myValue = 5j
#Imprimimos el valor de la variable myValue
print(myValue)
#Para saber el tipo de una variable usamos type
print(type(myValue))
#Cuando usamos la funcion str() vamos a imprimirel valor de la variable como si fuera texto
print(str(myValue) + "is of the data type" + str(type(myValue)))
#Las variables en Py pueden cambiar los valores que les damos
myValue = True
#Imprimimos el valor de la variable myValue
print(myValue)
#Para saber el tipo de una variable usamos type
print(type(myValue))
#Cuando usamos la funcion str() vamos a imprimirel valor de la variable como si fuera texto
print(str(myValue) + "is of the data type" + str(type(myValue)))
#Las variables en Py pueden cambiar los valores que les damos
myValue = False
#Imprimimos el valor de la variable myValue
print(myValue)
#Para saber el tipo de una variable usamos type
print(type(myValue))
#Cuando usamos la funcion str() vamos a imprimirel valor de la variable como si fuera texto
print(str(myValue) + "is of the data type" + str(type(myValue)))