This is a simple calculator program that performs various mathematical operations and runs in a command line interface. It was developed on Microsoft Visual Studio 2019 with the C++ programming language.
cpp-cli-calculator was able to perform basic arithmetic operations such as addition(+), subtraction(-), multiplication(*) and division(/)).
cpp-cli-calculator-v2 can perform mathematical operations such as exponents and factorials. It can list the prime numbers up to a certain number. It can also roll random backgammon dice by running the random number generator.
In summary, in the previous version we were able to perform:
Arithmetic Operations:
- Addition
- Subtraction
- Multiplication
- Division
In this new version, we can perform:
- Calculating arithmetic operations
- Calculating factorial numbers
- Calculating exponential numbers
- Finding a list of prime numbers
- Rolling a random backgammon dice
Finally, I would like to point out that. I could do this development by updating over the first version, tagging or releasing it. However, instead of changing the simple code structure and detailed README description of the first version, I wanted to open a new repository.
This is an advanced version of the first program I developed while learning the basics of programming. You can access the source code of this program and run and test it in your own development environment.
Technology and tools I used while developing this program:
- Microsoft Visual Studio 2019
- C++
- Git
- GitHub
Clone the repository:
$ git clone https://github.com/headdawnLight/cpp-cli-calculator-v2.git
Run and test the source codes in your own development environment.
Step by step
- Enter the number code to perform one of the listed in the menu.
- If you choose the number 1, you can calculate simple arithmetic operations.
- If you choose number 2, you can calculate the factorial of a positive integer.
- If you choose the number 3, you can calculate exponents.
- If you choose the number 4, you can list the prime numbers up to a certain number.
- Finally, if you choose the number 5, the random number generator generates two random numbers from 1 to 6, just like rolling a backgammon dice.
MIT License
Copyright (c) 2021 Sertan Işık
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.