The first problem is that you do the same thing regardless of the truth of defined $ignore{$word}.
You could use the following:
Or maybe you want to skip the entire line:perl -pe's/\band\b//g;' in > out
perl -ne'print if !/\band\b/;' in > out
In reply to Re: Extract word
by ikegami
in thread Extract word
by etheral
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |