Python Code Bisection Linear Interpolation