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

Re: Deep recursion on subroutine

by choroba (Chancellor)
on Sep 04, 2013 at 12:39 UTC ( #1052327=note: print w/replies, xml ) Need Help??


in reply to Deep recursion on subroutine

From the theoretical perspective, you can be never sure. But, in practice, your computer will run out of memory far before going into infinite recursion. If you can find an upper bound of the depth (e.g. the size in bytes of the input file), you can check whether your current depth is not beyond the bound.
لսႽ ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1052327]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (4)
As of 2016-12-04 04:11 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (61 votes). Check out past polls.