in reply to Re^15: To read files from two dir
in thread To read files from two dir
TITS (Try It To See):
use strict; use warnings; for my $vmstr ("0", "01", "00", "000", "1", "10") { my ($digits) = "-$vmstr" =~ /-(\d+)$/; print "'$vmstr': \$digits '$digits'\n"; }
Prints:
'0': $digits '0' '01': $digits '01' '00': $digits '00' '000': $digits '000' '1': $digits '1' '10': $digits '10'
which is not what I understood you to want. Try adjusting the match to /-0*(\d+)$/.
|
---|