Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re^3: Avoiding repeated undefs

by rsFalse (Hermit)
on Feb 28, 2019 at 00:15 UTC ( #1230644=note: print w/replies, xml ) Need Help??


in reply to Re^2: Avoiding repeated undefs
in thread [Solved] Avoiding repeated undefs

Similar approach:
( my $key, (undef) x 5, my $val) = split(/\s+/, $_);
Note: 'undef' must be enclosed with parentheses to force list context for 'x' operator.

Replies are listed 'Best First'.
Re^4: Avoiding repeated undefs
by choroba (Archbishop) on Feb 28, 2019 at 06:37 UTC

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (4)
As of 2020-01-24 02:36 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Notices?