def make_rolling_features(cols_roll, windows, agg_funcs, df_input):
	"""
	Make and add rolling features to the input dataframe given the columns, windows and aggregate function. 
	And record features created.

	Parameters:
	-----------
	cols_roll -- (list) a list of column names used to make rolling features
	windows -- (list) a list of int used as the window of making rolling features
	agg_funcs -- (list) a list of function names used as aggregate function for making rolling features
	df_input -- (pd DataFrame) the input dataframe which contains the features used for making rolling features
	
	Return:
	-----------
	cols_created_this_roll -- (list) a list of column names of the created rolling features
	df_output -- (pd DataFrame) the output dataframe containing all the rolling features
	"""
	cols_created_this_roll = []
	df_output = df_input.copy()
	for col in cols_roll:
		for t in windows:
			for fun in agg_funcs:
				new_col = col+'_last'+str(t)+'_'+fun
				cols_created_this_roll.append(new_col)
				df_output.loc[:, new_col] = getattr(df_input[col].rolling(t, min_periods=1), fun)().copy()

	return cols_created_this_roll, df_output