>perl -wMstrict -le "my @lines = ('xx', '0 xx', '1 xx 3.2'); ;; 'Zonk' =~ m{ (\w+) }xms; ;; my @filtered = map { /.*(?<!\d)(\d+)/; $1 // '' } @lines; printf qq{'$_' } for @filtered; " 'Zonk' '0' '2'
In reply to Re^2: Array Filter and Lookahead
by AnomalousMonk
in thread Array Filter and Lookahead
by daugh016
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |