so i'm writing a program to do LaGrange interpolation. For those who aren't really familiar with the formulas for it, its like a series. I want to make this function into an array and for each value of the array have a certain formula plugged in, but I don't really know how to do it. The array is size n-1 (where n is inputted by the user as size). An example is
(where the user the xvalues are an entirely seperate array-that the user inputs- and y is input right before the array of P is declared)
hopefully this is straightforward..