Implement part 1 of interpolation and spline exercise.