-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcl20.py
More file actions
33 lines (26 loc) · 729 Bytes
/
cl20.py
File metadata and controls
33 lines (26 loc) · 729 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
30
31
32
33
print("#################################")
print("Calculadora de solo una variable")
print("#################################")
print("Panel de opciones ")
print("Presione 1 para suma ")
print("Presione 2 para restar ")
print("Presione 3 para Multiplicar ")
print("Presione 4 para Dividir ")
clav = int(input("Clave a elegir: \n"))
if clav == 1:
nu=int(input("Primer valor: "))
nd=int(input("Segundo valor: "))
res = nu + nd
print(res)
elif clav == 2:
nu=int(input("Primer valor: "))
nd=int(input("Segundo valor: "))
res = nu - nd
print(res)
elif clav == 3:
nu=int(input("Primer valor: "))
nd=int(input("Segundo valor: "))
res = nu * nd
print(res)
else:
print("ya")