On Thu, Jul 10, 2003 at 03:26:14PM +0900, Daniel Carrera wrote:
> Okay, so we agree on:
> 
>    re = ARGV.shift;
>    ARGF.each{|x| puts x if x =~ /#{re}/}

Incidentally, you could make it more efficient by building the regex only
once:

     re = /#{ARGV.shift}/
     ARGF.each{|x| puts x if x =~ re}

Regards,

Brian.