Computing system based on the number 36
Find a file
2026-02-02 11:46:17 +02:00
.drone.yml Add '.drone.yml' 2022-08-08 05:25:48 +00:00
.gitignore copy from github 2021-05-11 23:21:06 +03:00
abcex.go update Convert method to support conversion from/to hex and update tests 2026-02-02 11:46:17 +02:00
abcex_test.go update Convert method to support conversion from/to hex and update tests 2026-02-02 11:46:17 +02:00
CHANGELOG update Convert method to support conversion from/to hex and update tests 2026-02-02 11:46:17 +02:00
go.mod v4 2025-01-06 21:37:40 +02:00
README.md update Convert method to support conversion from/to hex and update tests 2026-02-02 11:46:17 +02:00

abcex

Build Status

Computing system based on the number 62, 36 or 16

Usage

Encode(int, int) -> string - convert number into string based on given base.

Decode(string, int) -> int - convert from encoded string into number based on given base.

Convert(string, int, int) -> string - convert encoded string from one base to another.

Valid(string, int) -> bool - check if string is valid for given base.

History

Version 1 - based on 32: number and case insensitive letters

Version 2 - failed release

Version 3 - based on 62: number and case sensitive letters

Version 4 - support both versions, based on 62 and 32

Comparisons

DEC             | abcex.BASE36  | shorter
-----------------------------------------
12              | c             | 2:1
100             | 2s            | 3:2
2000            | 1jk           | 4:3
1000000         | lfls          | 7:4
1000000000      | gjdgxs        | 10:6
1000000000000   | cre66i9s      | 13:8

DEC             | abcex.BASE62  | shorter
-----------------------------------------
12              | C             | 2:1
100             | 1c            | 3:2
2000            | WG            | 4:2
1000000         | 4C92          | 7:4
1000000000      | 15ftgG        | 10:6
1000000000000   | HbXm5a4       | 13:7