Oct-06-2018, 07:48 AM
Don't lose any sleep over this, but Just keep in mind that with recursion every iteration creates an new entry in memory, so if you are dealing with Big data you may run into memory errors. This doesn't usually happen, but you will probably run across it from time to time, and need to keep it in the back of your mind so that you can recognize it.
Typical python stack frame is around 500 bytes.
There's a good writeup on this here: https://www.python-course.eu/recursive_functions.php
Typical python stack frame is around 500 bytes.
There's a good writeup on this here: https://www.python-course.eu/recursive_functions.php