How to find range overlap in python?,"list(range(max(x[0], y[0]), min(x[-1], y[-1]) + 1))"