jaraco / jaraco/inflect

Why a extra blank appeared in calling number_to_words to convert 541140 to words with andword=','

Open
#229 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
1.1k
Forks
127
PR merge metrics
No merged PRs in 30d

Description

code:
`import inflect

p = inflect.engine()

print(p.number_to_words(541440))
print(p.number_to_words(541440, andword=','))
`
result:(the extra blank appear after four hunred)
**five hundred and forty-one thousand, four hundred and forty
five hundred, forty-one thousand, four hundred , forty**

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reproducing the provided p.number_to_words(541440, andword=',') example and compare it with the default output. Trace the number_to_words entry point and locate existing tests for number formatting or andword handling. Done means the comma-separated wording has no unintended space and the relevant tests cover the corrected output.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.