I think I have the minimum and index of x:  but I don't know how to put them together in the minimum function: 