- Create a file named mymath.py containing:
- A function add(a, b) → returns the sum of two numbers.
- A function sub(a, b) → returns the difference of two numbers.
- A variable PI = 3.14.
In another file calculator.py:
Write a program called that imports sub as s and add from mymath.py.
It should ask the user to choose an operation (add or sub) and enter two numbers, then print the result.
Choose operation (add/sub): add
Enter first number: 7
Enter second number: 5
Result = 12