Jump to content

IntToWord


Recommended Posts

Odd

If I try this with "Local $iNum = 18"

I get NineTeen !

Never mind. Found the problem myself just added the missing link like so:

" Local $asTeens[9] = ["eleven", "twelve", "thirteen", "fourteen", "fifteen", "sixteen", "seventeen", "eighteen", "nineteen"] "

Did not have the "eighteen" ;)

Link to comment
Share on other sites

and you definitly don't want to enter 19 for $iNum.

If you look at this carefully you should spot the problem.

Local $asTeens[8] = ["eleven", "twelve", "thirteen", "fourteen", "fifteen", "sixteen", "seventeen", "nineteen"]

EDIT:

mat is sharp, he just doesn't count too well.

Edited by GEOSoft

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

and you definitly don't want to enter 19 for $iNum.

If you look at this carefully you should spot the problem.

EDIT:

mat is sharp, he just doesn't count too well.

I'm not sure why it wasn't fixed in the one in this thread, as it was fixed in the other one, posted on the same day... I reckon someone's got a subtle sabotage campaign on the go ;)

A* maths doing it a year early thank you very much, that means I know up to and including my ten times tables :)

Link to comment
Share on other sites

That's not too surprising. It looks like:

Local $asTeens[8] = ["eleven", "twelve", "thirteen", "fourteen", "fifteen", "sixteen", "seventeen", "nineteen"] 
;should be
Local $asTeens[9] = ["eleven", "twelve", "thirteen", "fourteen", "fifteen", "sixteen", "seventeen", "eightteen", "nineteen"]

I'm guessing a value of 19 would give you a nice dimension range exceeded error.

Edit: So there was a second page :/ I figured the last post on the page1 was was the last one in the topic.

Edited by Tvern
Link to comment
Share on other sites

Not only does Mat not count too well, Tvern doesn't spell so well either. ;)

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

Not only does Mat not count too well, Tvern doesn't spell so well either. ;)

That's a well known fact. Luckily I can hide behind the "I'm dutch isn't that weird?" excuse, aswell as the "makes more sense my way" argument.

hey 500th post.. Who do I talk to for the t-shirt?

Edited by Tvern
Link to comment
Share on other sites

We can excuse you for being Dutch, after all we've been excusing others (no names mentioned Jos) for years for the same reason.

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

Link to comment
Share on other sites

hey 500th post.. Who do I talk to for the t-shirt?

Here. Erm, Mug, Clock, Mouse mat, but no t-shirt. ???

"Straight_and_Crooked_Thinking" : A "classic guide to ferreting out untruths, half-truths, and other distortions of facts in political and social discussions."
"The Secrets of Quantum Physics" : New and excellent 2 part documentary on Quantum Physics by Jim Al-Khalili. (Dec 2014)

"Believing what you know ain't so" ...

Knock Knock ...
 

Link to comment
Share on other sites

The one from the other post seems to have a problem, as feeding it "100200" results in "one hundred and thousand two hundred". The one in this post returns "one hundred and thousand two hundred and".

I get "one hundred thousand two hundred". Are you talking about the one that people should be using in example scripts here? Or the one in this thread. The one I just linked to is much better, and has NumFromWord added in as a bonus. I suppose I'd better edit the offending post in this thread to have a more up to date version. ;)
Link to comment
Share on other sites

I get "one hundred thousand two hundred". Are you talking about the one that people should be using in example scripts?

That's crazy (or I am)... Could have sworn I cut it out of the old thread to play with, and it misbehaved. I started from scratch this time, and it's acting fine. So, "Operator error", apparently. I might try to work the "and" verbage into my little 33-liner, if I can remember how I got it to work in the first place ;)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...