Skip to main content

Add, Multiply, Mod, Divide Large number

Project description

Infinite Precision

Adding big big number!!

Usage

from infp import BigNumber

num1 = BigNumber("1648976548.65498")
num2 = BigNumber("-4564984945.654")
sum = num1 + num2       # -2916008396.99902
print(sum)      
num1 = BigNumber("10")
num2 = BigNumber("10")
sub = num1 - num2
print(sub)              # 0
ans = BigNumber("132") / BigNumber("132")
print(ans)              # 1

Unit Test

  • Install pytest if haven't
pip install pytest
  • Run test command
pytest

Run the main program example

python main.py

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

infp-0.0.3.tar.gz (3.9 kB view hashes)

Uploaded Source

Built Distribution

infp-0.0.3-py3-none-any.whl (3.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page