diff --git a/My_second_comit b/My_second_comit new file mode 100644 index 0000000..638b80e --- /dev/null +++ b/My_second_comit @@ -0,0 +1,30 @@ +a = int(input("Введи первое число")) +b = int(input("Введи первое число")) +d = str(input("Что будем делать?")) +if d == "*": + c = a*b + print("Твой ответ", c) +elif d == "умножить": + c = a*b + print("Твой ответ", c) +elif d == "сложить": + c = a+b + print("Твой ответ", c) +elif d == "+": + c = a+b + print("Твой ответ", c) +elif d == "-": + c = a-b + print("Твой ответ", c) +elif d == "разность": + c = a-b + print("Твой ответ", c) +elif d == "/": + c = a/b + print("Твой ответ", c) +elif d == "делить": + c = a/b + print("Твой ответ", c) +else: + print("Такое не умеем") + \ No newline at end of file diff --git a/calculator.py b/calculator.py deleted file mode 100644 index 9a92d51..0000000 --- a/calculator.py +++ /dev/null @@ -1,10 +0,0 @@ -a=int(input("1 цифра: ")) -c=input("Выберите способ вычисления(- или /): ") -b=int(input("2 цифра: ")) -if c=="-": - print("Ответ: ", a-b) -elif c=="/": - print("Ответ: ", a/b) -else: - print("Вы ввели неправильное значение!!!") - \ No newline at end of file