A simple calculator package for basic math operations
Project description
'''# Simple Calculator - Ahmed Khaled
A simple Python library for basic arithmetic operations: addition, subtraction, multiplication, and division.
Installation
To install the package, use the following command:
pip install simple-calculator-ahmed-khaled
Usage
from simple_calculator_ahmed_khaled.calculator import add, subtract, multiply, divide
# Addition
result_add = add(15, 7)
print(f"Addition: {result_add}")
# Subtraction
result_subtract = subtract(15, 7)
print(f"Subtraction: {result_subtract}")
# Multiplication
result_multiply = multiply(15, 7)
print(f"Multiplication: {result_multiply}")
# Division
result_divide = divide(15, 7)
print(f"Division: {result_divide}")
# Division by zero
try:
divide(15, 0)
except ValueError as e:
print(e)
'''
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file simple-calculator-ahmed-khaled-0.1.0.tar.gz.
File metadata
- Download URL: simple-calculator-ahmed-khaled-0.1.0.tar.gz
- Upload date:
- Size: 2.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0rc1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b334eae841facd823b9587096c3d17097d036cae1e5efd49b203d7dc9efa534c
|
|
| MD5 |
698ebede03dea7085b6d571cd5ff5124
|
|
| BLAKE2b-256 |
284ee9708a7d52bfcdcd2d7c46ce95ba4a857fcef849c8b98fa14fe1ed8f3f93
|
File details
Details for the file simple_calculator_ahmed_khaled-0.1.0-py3-none-any.whl.
File metadata
- Download URL: simple_calculator_ahmed_khaled-0.1.0-py3-none-any.whl
- Upload date:
- Size: 3.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.0rc1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
cffc3d4cfda6cce7819d76a9d9994ab9b64f57d3e2ef47c6907e5aa80de4f997
|
|
| MD5 |
a53e00eeb5d4cb0b32f08ac30b58122d
|
|
| BLAKE2b-256 |
d12fca648f382408731abf968e8988902c5346cb4dc73b8c55a9561d28a75bc4
|