Skip to content

preenu91/SimpleCalculator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Simple Calculator

A simple C++ console calculator.
It can perform addition, subtraction, multiplication, and division, and allows repeated calculations in one run.

How to Run

  1. Download or clone this repository.
  2. Open the SimpleCalculator.cpp file in your C++ IDE (e.g., Visual Studio).
  3. Build and run the program.
  4. Enter two numbers and an operator (+, -, *, /) when prompted.
  5. Continue calculating until you choose to exit.

Example Output

Enter two numbers: 8 2 Enter operator (+, -, *, /): * Result: 16 Do you want to continue? (y/Y for yes, n/N for no): y Enter two numbers: 10 0 Enter operator (+, -, *, /): / Error: Division by zero! Do you want to continue? (y/Y for yes, n/N for no): n

Future Improvements

  • Add more operations (modulus, power)
  • Keep a history of calculations

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages