On Oct 12, 2007, at 9:05 PM, Brian Adkins wrote: > D'oh! Old code failed for (0...0) > > class Range > alias orig_max max > def max > if ( self.begin.kind_of?(Integer) && > self.end.kind_of?(Integer) && > ( self.exclude_end? ? > self.begin < self.end : > self.begin <= self.end ) ) > self.exclude_end? ? self.end - 1 : self.end > else > orig_max > end > end > end > > p ( -1 .. -4 ).max ;-) a @ http://codeforpeople.com/ -- share your knowledge. it's a way to achieve immortality. h.h. the 14th dalai lama