what happened here? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0
2nd Jun 2022, 1:12 AM
Mouadh Bouziane
Mouadh Bouziane - avatar
1 Answer
+ 3
You're using recursion. You have a base case which is if (a<= 0) and then you're calling the function while decreasing the input variable, which is essentially making it countdown. It can be compared to something such as a loop.
2nd Jun 2022, 1:43 AM
Justice
Justice - avatar