On 02/29/2008 11:21:52 AM, Tom Phoenix wrote:
-> On Thu, Feb 28, 2008 at 4:28 PM, MK <[EMAIL PROTECTED]>
-> wrote:
->
-> >  # do not "use strict"

because i don't.  that's all. but wait a minute...

-> >  The purpose of
-> >  return is to exit the subroutine at some arbitrary point and the
-> return
-> >  value is limited (usually to indicate "success" or "failure").
->
-> What does "the return value is limited" mean? Can you give a concrete
-> example of what you're talking about?

Okay, now i apologize for being stupid whilst jumping a gun. By return I meant that "return" called alone simply gives you a zero. But this clearly misses a point of clearer educational value, vis. what we all already believe:

return "anything";

is exactly that. However, vijay's question implies this method isn't working for him, and the (unexplained) problems with multiple nested subroutines might be resolved by just using global ("myless") variables defined within the functions.

Of course, once that works, the script might be further resolved back into the "$x=function()" style. I seem to believe i have had that experience myself. Maybe...soon...





--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to