3 ms·
Poll: Loops vs. Recursion
Even after learning to understand recursion better, by reading SICP and similar books, I find recursive code generally more difficult to reason about than iterative code.
I'm wondering if this is only because I learned about loops first, so I thought I'd create this poll.
- mmphosis 4y agovs. Map vs. Generator vs. Scheduler vs. Unrolled-loop vs. ...
- ibash 4y agoThey’re both easy to reason about, you just need to learn about the recursion fairy: https://jeffe.cs.illinois.edu/teaching/algorithms/book/01-recursion.pdf https://jeffe.cs.illinois.edu/teaching/algorithms/book/01-re...