This question is actually generic to all programming languages. How can I know in which iteration I am using an recursive funtion. This is my python code: