Java program to make simple calculator

In this post, we will see how to create a simple calculator in java.
This calculator program performs 4 basic operatios – Addition, Substraction, Multiplication and division.It uses Switch case to choose operation you want to perform.

Output:

1. Addition
2. Subtraction
3. Multiplication
4. Division
5. ExitEnter your operation : 3
Enter Two Number : 5 7
Multiplication of numbers is 35.0
—————————————
1. Addition
2. Subtraction
3. Multiplication
4. Division
5. ExitEnter your operation : 1
Enter Two Number : 55 25
Addition of numbers is 80.0
—————————————
1. Addition
2. Subtraction
3. Multiplication
4. Division
5. ExitEnter your operation : 5

That’s all about java program to make simple calculator.

Was this post helpful?

Leave a Reply

Your email address will not be published. Required fields are marked *