tehamalab / tarakimu

A Python based utility for Swahili and English number to words conversion.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Tarakimu

Documentation Status Updates

A tool for Swahili and English number to words conversion written in Python

Installation

To install tarakimu library you can use pip:

$ pip install tarakimu

Basic Usage

Examples

Using Python

from tarakimu import num_to_words

num_to_words('88')  # returns 'themanini na nane'

num_to_words(88.88)  # returns 'themanini na nane nukta nane nane'

num_to_words('-88000000')  # returns 'hasi kuadrilioni themanini na nane'

num_to_words('88', lang='en')  # returns 'eighty eight'

Using command line interface

$ tarakimu numtowords 88  # writes to the standard output 'themanini na nane'

OR

$ tarakimu numtowords 88 -l en  # writes to the standard output 'eighty eight'

About

A Python based utility for Swahili and English number to words conversion.

License:Other


Languages

Language:Python 90.0%Language:Makefile 10.0%