This Python script is a simple calculator that allows for basic arithmetic operations such as addition, subtraction, multiplication, division, and average calculation. It takes user input to perform the desired operation and displays the result.
-
Run the script:
python main.py
-
Follow the prompts to choose an operation and input the required numbers.
-
View the result of the selected operation.
- Addition (
1): Sum of multiple numbers. - Subtraction (
2): Difference between two numbers. - Multiplication (
3): Product of multiple numbers. - Division (
4): Quotient of two numbers. - Average (
5): Average of multiple numbers.
To exit the calculator, enter -1 when prompted for your choice.
This calculator clears the console after each operation for a better user experience. While showing the result it waits for 5 seconds before switching to next prompt