a simple calculator
Project description
README
Calculator Package
The Calculator package provides a simple calculator class with basic arithmetic operations.
Features
Addition: Add a value to the calculator memory.
Subtraction: Subtract a value from the calculator memory.
Multiplication: Multiply the calculator memory by a value.
Division: Divide the calculator memory by a value (non-zero).
(N) Root: Calculate the (N)th root of the calculator memory.
Reset: Reset the calculator memory to 0.0.
Installation
You can install the Calculator package using pip:
bash
Copy code
pip install calculator-package
Usage
python
Copy code
from calculator_package import Calculator
Create a Calculator instance
calculator = Calculator()
Perform operations
calculator.add(5.0)
calculator.subtract(2.0)
calculator.multiply(3.0)
calculator.divide(2.0)
calculator.nroot(2)
result = calculator.memory
print("Result:", result)
Reset the calculator memory
calculator.reset()
Contributing
Contributions are welcome! If you have any suggestions, bug reports, or feature requests, please open
an issue or submit a pull request.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
calculator_sf-0.1.0.tar.gz
(5.7 kB
view hashes)
Built Distribution
Close
Hashes for calculator_sf-0.1.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9c64e474e3994d849c67e4f2d4d3fbb99e297a6fb1392c55d026d9267b0d901b |
|
MD5 | fbce7833c6a82af0c3f5c0c6fc2e8eb1 |
|
BLAKE2b-256 | 551912ea8527eed940ea76d552101957cd15a8ac0975ab45cfd94b179c02e00a |