You've already forked Curso-lenguaje-python
ADD dia 08
This commit is contained in:
10
dia_08/02_pruebas_paquete/ejercicio.py
Normal file
10
dia_08/02_pruebas_paquete/ejercicio.py
Normal file
@@ -0,0 +1,10 @@
|
||||
from paquete_ma import suma_y_resta
|
||||
from paquete_ma.subpaquete_ma import saludo
|
||||
|
||||
# Importado del paquete
|
||||
suma_y_resta.suma(1, 5)
|
||||
|
||||
suma_y_resta.resta(15, 3)
|
||||
|
||||
# Importado del subpaquete
|
||||
saludo.hola()
|
||||
0
dia_08/02_pruebas_paquete/paquete_ma/__init__.py
Normal file
0
dia_08/02_pruebas_paquete/paquete_ma/__init__.py
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,2 @@
|
||||
def hola():
|
||||
print('hey!!')
|
||||
6
dia_08/02_pruebas_paquete/paquete_ma/suma_y_resta.py
Normal file
6
dia_08/02_pruebas_paquete/paquete_ma/suma_y_resta.py
Normal file
@@ -0,0 +1,6 @@
|
||||
def suma(num1, num2):
|
||||
print(num1 + num2)
|
||||
|
||||
|
||||
def resta(num1, num2):
|
||||
print(num1 - num2)
|
||||
Reference in New Issue
Block a user