Hi --

On Fri, 2 Dec 2005, Bob Showalter wrote:

> David A. Black wrote:
>> You can do:
>>
>>   enum.any? {|e| ... }
>> 
>> to get a true/false result.
>
> Excellent! I assume that would stop iterating as soon as a true was found?

Yes:

irb(main):004:0> [1,2,3,4].any? {|e| puts e; e > 1 }
1
2
=> true


David

-- 
David A. Black
dblack / wobblini.net