Project Portfolio

Python Calculator

This is a custom python calculator I made which includes a imported python module, if statements, loops, variables, functions, keyboard input, constants, and calculations. Below is an image of the source code for the calculator along with the imported file of math functions the calculator requires.

Python Calculator Code

Slide left to see the imported mathFunctions module.
Slide right to see the mathCalcuator module.

Project Portfolio

How it Works

There are three inputs required for this calculator. First, the user enters a number. Second, the user will select the operation they would like to use. And third, the user will enter another number. Finally, the calculator will perform the math operation the user selected and output the correct answer. This will continue in a loop for a maximum of 5 times before the program terminates.

Math Functions Performed

The calculator can perform addition, subtraction, multiplication, division, and modulo operations. The idea of importing these functions into the main file is that it is possible to easily import the functions for other purposes as well.

Calculator in Use