Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
Ah, but I'm using triple dot instead of double dot. The triple dot range operator does not include the end value.
http://stackoverflow.com/questions/9690801/difference-between-double-dot-and-triple-dot-in-range-generation
Hi, while I was writing the solution I took it for granted but when you asked the question it made me search for why it works, here is a link expalinaing why it works for ruby 1.9+.
https://stackoverflow.com/questions/17355316/hash-ordering-preserved-between-iterations-if-not-modified
May be worth reading the discussion on use of "and" in number representation here: http://www.codewars.com/kata/525c7c5ab6aecef16e0001a5/discuss#5276d6654c2333791a00027c
Thanks!
Ah, we may have a killer objection here :-) ...in that's how most people speak:
"the house costs two hundred thirty thousand, four hundred and ninety-nine dollars."
"the house costs two hundred and thirty thousand four hundred and ninety nine pounds."
I think you're right, and that this alone could make the problem too clunky for codewars in that it's not a neat, unambiguous problem with with a clear solution.
I'll make such improvements as I can following your helpful criticism.
First, I am surprised that you want the way to write a number to be defined, if it's not obvious then to explain it would take, IMO, far too long to do unambiguously. Further, I'm not sure what you mean by allowed/not allowed. I've said the range of possible numbers; what might not be allowed, as an example for me?
Second, yes the choice of how to represent 'point zero' is quite arbitrary, it's just (slightly) more difficult that way.
Clearly you don't like this problem. Fair enough; and if the community doesn't like it, I can delete it.