https://github.com/frectonz/ethiopic-numerals
Convert to Ethiopic Numerals
https://github.com/frectonz/ethiopic-numerals
Last synced: 9 months ago
JSON representation
Convert to Ethiopic Numerals
- Host: GitHub
- URL: https://github.com/frectonz/ethiopic-numerals
- Owner: frectonz
- License: mit
- Created: 2022-08-20T16:40:39.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2022-08-28T08:16:15.000Z (almost 4 years ago)
- Last Synced: 2025-04-10T23:43:40.806Z (about 1 year ago)
- Language: Rust
- Homepage:
- Size: 6.84 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ethiopic-numerals
An algorithm that converts numbers to ethiopic numerals.
This is an implementation of [Ethiopic Numeral Algorithm](https://www.geez.org/Numerals/) from [geez.org](http://www.geez.org/).
The test cases are taken from [here](https://www.geez.org/Numerals/NumberSamples.html).
## Install
add the following to your `Cargo.toml`
```
ethiopic-numerals = "0.1.0"
```
## Examples
```
0 => ""
1 => "፩"
2 => "፪"
3 => "፫"
4 => "፬"
5 => "፭"
6 => "፮"
7 => "፯"
8 => "፰"
9 => "፱"
10 => "፲"
20 => "፳"
30 => "፴"
40 => "፵"
50 => "፶"
60 => "፷"
70 => "፸"
80 => "፹"
90 => "፺"
100 => "፻"
500 => "፭፻"
10_000 => "፼"
42 => "፵፪"
78 => "፸፰"
18 => "፲፰"
1000 => "፲፻"
100_000 => "፲፼"
111 => "፻፲፩"
666 => "፮፻፷፮"
1_000_000 => "፻፼"
10_000_000 => "፲፻፼"
123 => "፻፳፫"
1111 => "፲፩፻፲፩"
1234 => "፲፪፻፴፬"
6666 => "፷፮፻፷፮"
1001 => "፲፻፩"
11111 => "፼፲፩፻፲፩"
111111 => "፲፩፼፲፩፻፲፩"
```