|
| 1 | +#Este es el sitio oficial del programa# |
| 2 | +#https://www.python.org/ |
| 3 | +#La sintaxis para crear un comentario es con el simbolo de numeral (#) |
| 4 | +''' |
| 5 | +O se pueden crear comentarios |
| 6 | +multinlinea con tres comillas al inci |
| 7 | +y al final del comentario |
| 8 | +''' |
| 9 | + |
| 10 | +this_is_a_variable = 1 |
| 11 | +there_is_no_constants_in_python = 2 |
| 12 | +this_is_a_string = "Hello World" |
| 13 | +this_is_a_number = 3 |
| 14 | +this_is_also_a_number = 3.14 |
| 15 | +this_is_a_boolean = True |
| 16 | +this_is_a_list = [1, 2, 3, "Paco", True, ["Perro, Gato, Pajaro"]] |
| 17 | +this_is_also_a_list = list([1,2,3,4,5,6,7,8,9,10]) |
| 18 | +this_is_a_tuple = (1, 2, 3, 4, 5) |
| 19 | +this_is_also_a_tuple = tuple((1, 2, 3, 4, 5)) |
| 20 | +this_is_a_set = {1,2,3,3,4,5,5} |
| 21 | +this_is_also_a_set = set([1,2,3,4,5,6,7,8,9,10,10,10,10,10]) |
| 22 | +this_is_a_dict = {"name": "Paco", "age": 25, "city": "CDMX"} |
| 23 | +this_is_also_a_dict = dict(name="Paco", age=25, city="CDMX") |
| 24 | + |
| 25 | +print("***Hola Python***") |
0 commit comments