Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Returning first element of an array from a function

by davido (Cardinal)
on Mar 17, 2004 at 07:47 UTC ( [id://337246]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    ( $foo ) = split ( /\./, $bar );
    
  2. or download this
    $foo = ( split ( /\./, $bar ) )[0];
    
  3. or download this
    ( $foo, $boo ) = ( split ( /\./, $bar ) )[ 1, 0 ];
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others meditating upon the Monastery: (4)
As of 2024-04-25 17:52 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found