to solve this specific problem, use perl -le"/pattern/ && print for @arr". this change handles the logic found in most (of my) one-liners.
~Particle *accelerates*
In reply to Re: One-liners: Conditionals in Loops
by particle
in thread One-liners: Conditionals in Loops
by David Caughell
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |