From: George Ogata Date: 2006-03-12T16:28:44+09:00 Subject: Re: unexpected behavior of range.each (Newbie extreme) Joe Percival writes: > seems like an odd definition of "include" (and "each") and inconsistent > with the behavior for arrays. Also, if (9..5) is not a valid range > specification why no error message? You can't error on construction simply because end < start. Consider: str[2..-1] > It seems to me that the definition of include (and each) for a range > could be made a bit more tollerant of direction by making it conditional > on the order of the endpoints. Ahh...Well... guess I ought to stop > complaining and just go back to learning the language :-) You could make Ranges go backwards, but that changes the soul of the ruby Range. (Confusion and code breakage everywhere.) I think having backwards ranges do nothing can also have its uses, though I can't conjure up a convincing one on the spot.