This is a simple calculator application built using Java and Swing. The calculator performs basic arithmetic operations such as addition, subtraction, multiplication, and division. It also includes functionalities for decimal numbers, clearing the input, and deleting the last digit.
- Basic Operations: Addition, Subtraction, Multiplication, Division
- Decimal Support: Ability to input decimal numbers
- Clear and Delete: Options to clear the input or delete the last digit
- Negation: Support for changing the sign of the input number
- Java: The programming language used for development.
- Swing: Java's GUI toolkit used for building the user interface.
- JFrame: For creating the main window.
- JPanel: For organizing the layout of buttons.
-
Clone the repository:
git clone https://github.com/yourusername/calculator.git cd calculator
javac calculator.java
Run the application:
java calculator
Launch the application.
Use the number buttons to input digits.
Select an operator to perform an operation.
Press = to see the result.
Use Clear to reset the input or Delete to remove the last digit.
Feel free to fork the repository and submit pull requests for any enhancements or fixes! License
This project is licensed under the MIT License - see the LICENSE file for details.
Thanks to the Java community for the resources and libraries that made this project possible.