Write an algorithm that calculates the list of the first n Fibonacci values. The input n represents the number of Fibonacci values to be calculated. The Fibonacci sequence is defined as follows: F0 = 0, F1 = 1, and Fn = Fn-1 + Fn-2. For example, if n = 5, the Fibonacci sequence would be 0, 1, 1, 2, 3.