Functional NegBin implementaion

This commit is contained in:
trotFunky 2020-11-06 22:34:02 +01:00
commit 82c2bb9f1b
9 changed files with 332 additions and 0 deletions

6
NegBin/README.md Normal file
View file

@ -0,0 +1,6 @@
# NegBin
Implements a class handling numbers in base -2.
Currently only the `+` operation is specific, all other operations (`-`, `~`, `*` with a scalar) are based on this one.
The implementation is quite naive and a bit slow but it works (~30x slower than integer addition on my machine). It can also convert to and from decimal !