Skip to main content

Practice ยท 2 of 3

A Stateful Fibonacci Generator

With your Generator<T> from the previous exercise, implement fibonacci(n) yielding the first n Fibonacci numbers (1, 1, 2, 3, 5, ...).

Difficulty: advanced

Back to lesson: Practice: Hands on the Handle