Comment Comment by scdlbx It's a lot easier to delete specific lines using sed. Also you can have sed do replacements to the n'th instance of something. Doing that in Perl is a bit more complicated and a lot less succint.$ echo "foo foo foo foo" | sed 's/foo/bar/3'foo foo bar foo parent scdlbx 12 years ago
$ echo "foo foo foo foo" | sed 's/foo/bar/3'
foo foo bar foo