Yohanes Santoso <[EMAIL PROTECTED]> writes:
> Edwin Pratomo <[EMAIL PROTECTED]> writes:
>
>> foo = %w(foo bar baz).collect do |fn|
>> fn = "#{fn}.txt"
>> fh = File.open(fn, 'r') rescue next nil
>
> fh = File.open(fn, 'r') rescue (next nil)Alternatively, since no-argument 'next' evaluates similarly as 'next nil': fh = File.open(fn, 'r') rescue next YS

