shemp has asked for the wisdom of the Perl Monks concerning the following question:

Hi all, I've been poking around for a while, looking for a module to handle turning spelled out numbers into digit strings. for instance, "twenty-six" should become "26". I have found a number of utilities for going the other way, i.e. turning 26 into twenty-six. Lingua::EN::Numbers or Number::spell will go that way.

If no such module exists, i'd be happy to write one, i'll definitely need it soon. Im just not really interested in re-inventing the wheel today :)

BTW: many of my spelled out numbers will be cardinals, i.e. twenty-sixth

Replies are listed 'Best First'.
Re: spelled out numbers to digits
by Enlil (Parson) on Jun 02, 2003 at 22:45 UTC
Re: spelled out numbers to digits
by tcf22 (Priest) on Jun 02, 2003 at 23:28 UTC
Re: spelled out numbers to digits
by Anonymous Monk on Jun 03, 2003 at 03:24 UTC
    Minor quibble:

    "Twenty-sixth" is an ordinal.
    "Twenty-six" is a cardinal.