A Python class for handling integers in arbitrary bases.
Project description
baseint
BaseInt is a small Python library for converting numbers in arbitrary bases.
Features
- Create BaseInt instances from integers, strings, lists and tuples.
- Convert between bases easily.
- Supports custom character maps.
Example
from baseint import BaseInt
b = BaseInt("1111", 2)
print(b.toDecimal()) # 15
print(f"{b.sconvert(8)!r}") # BI:8:17
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
baseint-0.0.8.tar.gz
(2.3 kB
view details)
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 baseint-0.0.8.tar.gz.
File metadata
- Download URL: baseint-0.0.8.tar.gz
- Upload date:
- Size: 2.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4fbc73ab8839dc4f524e2211e1ba403c6a818e7966110f47ba205f573e4ef71f
|
|
| MD5 |
d9b3b928846bd0a662e059c8692e7d1d
|
|
| BLAKE2b-256 |
0a7146a675043c908117520cdaeeb0f34052bb004bfece925a75d7cb8615b39d
|
File details
Details for the file baseint-0.0.8-py3-none-any.whl.
File metadata
- Download URL: baseint-0.0.8-py3-none-any.whl
- Upload date:
- Size: 2.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2a92e447e6c54b3de42b63447d4f03bf7cd5ef410200a13070e376f379e62081
|
|
| MD5 |
7e4df5c954c6c2df2ccb3a60930692af
|
|
| BLAKE2b-256 |
b817df3e27c790588379af122ebfc5f8e8cf5ac9dd209b1f7f0310f5ae336887
|