use warnings; use strict; while (<DATA>) { print if /thing1/ or /thing2/; } __DATA__ thing1 foo bar thing2 thing1 and thing2
prints:
thing1 thing2 thing1 and thing2
In reply to Re: Multiple strings in a file
by toolic
in thread Multiple strings in a file
by The_Last_Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |