Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re: Subroutine Produces Output but Fails to Return to Parent

by imp (Priest)
on Jan 18, 2007 at 23:04 UTC ( #595371=note: print w/ replies, xml ) Need Help??


in reply to Subroutine Produces Output but Fails to Return to Parent

The code you provided works for me after I add a line to print the result, so your problem is elsewhere.

You should always use both strict and warnings, as they will catch many common errors. In your example code you used mixed case in your variable names, which would be an easy place to introduce a typo.

After adding strict and warnings you should reduce the code to the simplest form that still behaves incorrectly. Chances are you will find the error by doing this, and if not we will be happy to assist you further. But please confirm that the reduced version still demonstrates the error (and that it runs of course).


Comment on Re: Subroutine Produces Output but Fails to Return to Parent

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (6)
As of 2014-10-01 09:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (392 votes), past polls