Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It's trivial to avoid infinite loops by adding some exit condition in case it takes too long, which is probably what you want here.

And obviously trivial to avoid recursion too.



Avoiding recursion isn’t always that trivial if there are intermediate functions between the first function is called again. More dynamic code with callback functions is another case making this difficult.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: