Skip to main content

A simple Python package for converting numbers to words (letters).

Project description

num2ltr

es

num2ltr is a simple Python package for converting numbers to words (letters).

It uses Spanish standard nomenclature, which means that most Spanish grammar rules are applied.

This package is still under testing, so you may experience inconsistencies.

This is also a personal project to improve my programming skills.

Installation

Use the package manager pip to install num2ltr.

pip install num2ltr

Or you can use the test package

pip install -i https://test.pypi.org/simple/ num2ltr

Usage

import num2ltr

# returns 'treinta y tres'
num2ltr.number_to_letters('33') # input must be a numeric string

Or you can use

from num2ltr import number_to_letters

# returns 'treinta y tres'
number_to_letters('33') # input must be a numeric string

Features

  • Converts numeric strings to Spanish words
  • Supports numbers up to 15 digits (for now)

Limitations

  • No decimal support yet
  • No negative numbers
  • No scientific notation

Roadmap

  • Decimal number support
  • Negative numbers
  • Support for larger numbers (up to 50 digits)

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to add or change.

Please make sure to update tests as appropriate.

License

MIT

Project details


Release history Release notifications | RSS feed

This version

1.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

num2ltr-1.0.tar.gz (8.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

num2ltr-1.0-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file num2ltr-1.0.tar.gz.

File metadata

  • Download URL: num2ltr-1.0.tar.gz
  • Upload date:
  • Size: 8.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for num2ltr-1.0.tar.gz
Algorithm Hash digest
SHA256 42eaacce05edc299494541c70ca2e22d918bf63eb78f08c73bf5ab565e6ec141
MD5 c53f03577faf082ae47894da2da2a3b3
BLAKE2b-256 a21a767aef8bb64d1f9b2217d8ea70f58772c2cbb8eede6432608c2d10aad6d9

See more details on using hashes here.

File details

Details for the file num2ltr-1.0-py3-none-any.whl.

File metadata

  • Download URL: num2ltr-1.0-py3-none-any.whl
  • Upload date:
  • Size: 5.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for num2ltr-1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 20ba38214a9852fe4f931d796ff4e96a459f3ea6f3b40b6269e8affc67e5d627
MD5 17757801170edb7383a470ea228f4c68
BLAKE2b-256 5bbcbfc0e025427295d8bf9489a7f90ea824e739b9c2b405004170557d4b574a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page