in reply to Matching a pattern two or four times
gives me:my @strings = ( 'Abc 21223.7 21225.33 22270.3 22280.1', 'Def 21600.23 24567.43' ); foreach (@strings) { my @arr = split(/\s+/, $_); print join(' - ', @arr), "\n"; }
All of your numeric values would be in $arr[1] to $arr[$#arr]Abc - 21223.7 - 21225.33 - 22270.3 - 22280.1 Def - 21600.23 - 24567.43
|
|---|