On 3/22/07, Eduardo Yáñez Parareda <eduardo.yanezNOSPAM / nospamgmail.com> wrote: > > tags_re = Regexp.new("\\b(?:#{tags.map {|t| > > Regexp.escape(t.chomp)}.join("|")})\\b") > > lines.delete_if {|l| l =~ tags_re } > > One more time I have to praise Ruby... > Thanks Jan. Now that I look at it: this is more like perl than ruby... Ron's version is probably a bit slower but much more readable...