Wyss Clemens <WYS / helbling.ch> wrote in message news:<2121D3CBCBE8D111B2C200805F0DF903F6AFD1 / HTKA60MS01NT>...
> By heart I would guess:
> 
> lines = File.readlines(ARGV[0])
> # create a file to append data found from the input file
> logfile = File.open("badwords.txt", "w+")
> # search for a word and print the entire line
> lines.each { | line  |
>    if /bob/i =~ line  
>      print line
>      logfile.write(line)
>    end
> }
> 
> Not tested though.
> Clemens 
> 

Very good! It does indeed do it! Now...since these are very large
files (40-60MB)...is this the best way to read them in?