You should remove these two functions:
def max(list): return max(list) def min(list): return min(list)Since they merely pass their arguments to another function, they aren't adding any value. Plus, they will likely cause errors and infinite recursion because they're either calling themselves (which calls themselves, which calls themselves, ...) or due to an ambiguous name since the functions max() and min() already exist.