Добавить My-second-comit
This commit is contained in:
parent
c5d6e7bd25
commit
b6c787a1ec
17
My-second-comit
Normal file
17
My-second-comit
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
a = int(input("Введите первую цифру"))
|
||||||
|
b = int(input("Введите вторую цифру"))
|
||||||
|
d = str(input("Выберите действие: */+-"))
|
||||||
|
if d == "*":
|
||||||
|
c = a*b
|
||||||
|
print("Ответ:",c)
|
||||||
|
elif d == "+":
|
||||||
|
e = a+b
|
||||||
|
print("Ответ:",e)
|
||||||
|
if d == "/":
|
||||||
|
f = a/b
|
||||||
|
print("Ответ:",f)
|
||||||
|
if d == "-":
|
||||||
|
y = a-b
|
||||||
|
print("Ответ:",y)
|
||||||
|
else:
|
||||||
|
print("error")
|
||||||
Loading…
Reference in New Issue
Block a user