This calculator project is a simple web-based calculator built using HTML, CSS, and JavaScript. It is capable of performing basic arithmetic operations such as addition, subtraction, multiplication, and division.
Installation
To use this calculator, simply download the files from the repository and open the index.html file in your web browser.
Usage
The calculator provides a simple interface with a screen to display input and output. Users can input numbers and operators by clicking on the buttons provided. The calculator can perform the following operations:
Addition (+) Subtraction (-) Multiplication (*) Division (/) To perform an operation, simply click the corresponding operator button after entering the first number, then enter the second number and click the equal (=) button. The result will be displayed on the screen.
To clear the input, click the CLEAR button.
Code
The JavaScript code for this calculator project is included in the file index.js. The code defines four functions for performing the arithmetic operations and an additional function for handling the operation based on the operator input. The code also includes an event listener to listen for button clicks and update the calculator display accordingly.
Contributing
Contributions to this project are welcome. If you have any suggestions or improvements, please feel free to fork the repository and create a pull request.
License
This project is licensed under the MIT License. Please see the LICENSE file for details.