WHY RECURSION,HOW RECURSION WORKS? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

WHY RECURSION,HOW RECURSION WORKS?

I didn't understand recursion! How much fast recursion is?

25th Jun 2019, 7:39 AM
Mahesh Muttinti
2 Answers
+ 1
RECURSION IS MOSTLY A MORE READABLE, BUT LESS EFFICIENT WAY IF LOOPING. IT IS USEFUL IF YOU WANT TO REMEMBER THE HISTORY OF THE FUNCTION
25th Jun 2019, 9:16 AM
Airree
Airree - avatar
+ 1
It's a function that generally, if it doesn't mean certain condition (exit condition) it will return a calling to the same function, so it'll loop until it reaches a condition where it doesn't return a calling to the same function
25th Jun 2019, 10:37 AM
alvaro.pkg.tar.zst
alvaro.pkg.tar.zst - avatar