min and max function renamed