Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: Help with argument to a subroutine

by krisahoch (Deacon)
on May 15, 2006 at 18:36 UTC ( #549565=note: print w/replies, xml ) Need Help??


in reply to Help with argument to a subroutine

unixhome,

There is more than one way to do it.
# 1. sub parse_header { # Get the first argument passed to the function/method. my $header = shift(); .... }
# 2. sub parse_header { # Get the first argument passed to the function/method. my $header = $_[0]; .... }
Kristofer A. Hoch
Senior Software Developer (P+++$)
Aptia Systems, Inc. (http://www.aptia.com)

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2022-05-25 19:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you prefer to work remotely?



    Results (90 votes). Check out past polls.

    Notices?