Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: using a subroutine

by mpeg4codec (Pilgrim)
on Aug 09, 2004 at 17:58 UTC ( #381314=note: print w/ replies, xml ) Need Help??


in reply to using a subroutine

Looking very good! It's a little redundant to pass the two arguments to directs() separately. You have the right idea with the foreach (@_) in the subroutine. Just pass the options like this:

&directs($home, $lib);
Remember, the rule for learning how to program is ``Read a lot, code a little, read a lot, code a little.'' Always keep experimenting. Good luck!


Comment on Re: using a subroutine
Download Code
Re^2: using a subroutine
by xjlittle (Beadle) on Aug 09, 2004 at 23:51 UTC
    I tried this way and it only read the last argument, $lib. However I may very well have missed something in the code that would cause both to be read. I like your philosophy though!

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (5)
As of 2014-07-13 21:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When choosing user names for websites, I prefer to use:








    Results (252 votes), past polls