<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def resample(grid, wl, flux):
 """ Resample spectrum onto desired grid """

    flux_rs = (interpolate.interp1d(wl, flux))(grid)
    return flux_rs