Metadata-Version: 2.1
Name: basewhat
Version: 1.1
Summary: A Python utility for encoding/decoding arbitrary-base numbers.
Home-page: https://helixteamhub.cloud/paulbissex/projects/basewhat/activity
License: MIT
Author: Paul Bissex
Author-email: paul@bissex.net
Requires-Python: >=3.6,<4.0
Classifier: Development Status :: 5 - Production/Stable
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Project-URL: Repository, https://helixteamhub.cloud/paulbissex/projects/basewhat/repositories/basewhat/tree/default
Description-Content-Type: text/markdown

﻿basewhat
========

A Python utility for encoding/decoding arbitrary-base numbers.

**Project home page**: <https://helixteamhub.cloud/paulbissex/projects/basewhat/>

**Author**: Paul Bissex <paul@bissex.net>

## Usage

    >>> b16 = BaseWhat(base=16)
    >>> b16.from_int(65535)
    'FFFF'
    >>> b16.to_int('DECAFBAD')
    3737844653
    >>> b32 = BaseWhat(digits="23456789ABCDEFGHJKLMNPQRSTUVWXYZ")
    >>> b32.from_int(32767)
    'ZZZ'
    >>> b32.from_int(9223372036854775808)
    'A222222222222'
    >>> b32.to_int('1900MIXALOT')
    Traceback (most recent call last):
    ...
    ValueError: Not a valid base 32 number

