Nokia Interview Question

Implement algorithm which prints n-members of Fibonacci sequence. Show iterative and recursive solution. Which is faster?

Interview Answer

Anonymous

Aug 10, 2020

Implemented iterative and recursive algorithm for Fibonacci sequence and added caching to recursive solution. Recursive is slower than iterative which is slower than recursive with caching.