Write an optimized function to generate the Fibonacci sequence, improving from naive recursion to an optimal iterative approach.