diff --git a/g.py b/g.py new file mode 100644 index 0000000..8e3e1c9 --- /dev/null +++ b/g.py @@ -0,0 +1,18 @@ +a = float(input("Введите первое число: ")) +operation = input("Выберите операцию: \n+ * - / \n") +b = float(input("Введите второе число: ")) + +if operation == "+": + print(a+b) + +elif operation == "*": + print(a*b) + +elif operation == "-": + print(a-b) + +elif operation == "/": + print(a/b) + +else: + print("Ошибка") \ No newline at end of file