.
Rarely. Only once.
All the time
What do you do at work? Also aren't iterative solutions preferred. I've tried recursion before but it got ripped apart in a code review.
Full stack developer. Not really all the time, but I've used it many times. From my point of view, recursion is preferred. I've actually ripped apart iterative solutions in CR
ALL. THE. TIME........ whenever I am conducting an interview that is.
Once when i was writing a parser
Yes, I was building a json serializer. Also, if you deal with file systems or systems which have some sort of tree structure, recursion is used to traverse the tree at times.
Few times, try functional programming it requires you to use tail recursion a lot.
A few times. Mostly when traversing a tree of some sort.
Yeah, how else do you ask someone to do Fibionacci.
Iteration with tabulation?
That’s option #2
I’ve used it once when iterating a multi-level hash map because iterative looked gross. Other than that not often.
Have you ever used recursion at work?
Memory limit exceeded. There's no base/exit condition here.