0

Recursion functions

Hi everyone i got some question about the recursion funcs... 1.how can i calculate it fast and easily if it came as a question in sololearn chllanges 2.How do do we know if we can use recursion in our program or not or which program need them actually? (in python)

8th May 2019, 9:05 AM
Amirabbas
Amirabbas - avatar
1 ответ
+ 4
1. I dunno. Stopped them a long time ago, never looked back. 2. If you can write a program that solves a given problem recursively you can write one :-D. You will know when you can't by getting something like a stackoverflow error msg or want to use it for extremely large values on a sub optimal algorithm. As you do not seem familiar with recursion check the top 5-10 results, read them to know more https://duckduckgo.com/?q=Learn+recursion #below are two posts offering differing perspectives on "Recursion or loops". See if they are of any use to you. https://www.sololearn.com/discuss/1671835/?ref=app https://www.sololearn.com/discuss/1782940/?ref=app
8th May 2019, 1:22 PM
Lord Krishna
Lord Krishna - avatar