Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^2: Extracting selected fields form file record (updated)

by rsFalse (Chaplain)
on Feb 07, 2022 at 12:27 UTC ( #11141200=note: print w/replies, xml ) Need Help??


in reply to Re: Extracting selected fields form file record (updated)
in thread Extracting selected fields form file record

We can omit parentheses, i.e. capture group number 1 isn't necessary.
my( $first, $second, $third, $fourth, $fifth, $sixth ) = ( $line =~ m/ +\S+/g )[ 0, grep { $_ % 2 == 1 } 1 .. 9 ];

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11141200]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2022-08-17 19:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?