Calculator
Project: Calculator Org/Course: The Odin Project Related files: index.html, javascript.js, style.css, README.md Date Started: July 29, 2022 Last Update: January 23, 2023
A brief synopsis on The Odin Project: For this project, The Odin Project gives basic instructions on what needs to be implemented but does not explain how. There is also a lot of area for flexibility in terms of style and specifics on how the program runs. The instructions to this project can be found at this link. https://www.theodinproject.com/lessons/foundations-calculator. I have attached a .txt file with my research and planning for the project. Note the plan was loosely followed as some of my logic has changed since originally planning the project.
The main goal of this project is to create a 4-function calculator using primarily Javascript but also HTML and CSS. The implementation uses event listeners for the buttons of the calculator. The reset button clears all the data that is stored.
This project includes utilization of basic data structures for some of the logic of the code. Functions were used heavily in the Javascript code. The utilization of a very small stack is the basis of how the calculator works. The stack can only have a maximum of 2 values at once since we are only able to evaluate a single pair of numbers at a time (per the instructions).
There are some stated possible bugs that are listed in the instructions in The Odin Project that were also addressed in the construction of the calculator. For, example division by 0.
I added some gradient styling using CSS and HTML. I also take advantage of the hover effect for the buttons of the calculator.