I think this:
print "$arg matches\n" if grep $arg, @valid;
Is equivalent to this:
So as long as @valid and $arg are not false, then the match will also be true. (If $arg is 0 (zero) then the second example will not always be true.)print "$arg matches\n" if grep { $arg } @valid;
jeffa
L-LL-L--L-LL-L--L-LL-L-- -R--R-RR-R--R-RR-R--R-RR B--B--B--B--B--B--B--B-- H---H---H---H---H---H--- (the triplet paradiddle with high-hat)
In reply to Re^4: Little annoying mistakes ... of others
by jeffa
in thread Little annoying mistakes ... of others
by szabgab
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |