Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: shift split grep question

by eyepopslikeamosquito (Chancellor)
on Nov 25, 2018 at 20:34 UTC ( #1226309=note: print w/replies, xml ) Need Help??


in reply to shift split grep question

To do it without modules try:

my ( undef, @headings ) = split ' ', (grep /^\s*AUID/, @lines)[0];
or using the "Baby cart" secret operator (see perlsecret):
my ( undef, @headings ) = split ' ', shift @{[grep /^\s*AUID/, @lines] +};

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2020-05-25 01:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If programming languages were movie genres, Perl would be:















    Results (142 votes). Check out past polls.

    Notices?