DB<34> @a = qw/xxBxx yyAyy zzNzz/ DB<35> @N = map {/^..(A|B)./} @a DB<36> x @N 0 'B' 1 'A' DB<37>
Hint: m// returns an empty list if there's no match
Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery
In reply to Re^3: do $n exist in grep?
by LanX
in thread do $n exist in grep?
by misterperl
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |