请帮忙看看为什么不对
import math def quadratic_equation(a, b, c): t=math.sqrt(b*b-4*a*c) return (-b+t)/(2*a) and (-b-t)/(2*a) print quadratic_equation(2, 3, 0) print quadratic_equation(1, -6, 5) 这段代码为什么不对,求解
import math def quadratic_equation(a, b, c): t=math.sqrt(b*b-4*a*c) return (-b+t)/(2*a) and (-b-t)/(2*a) print quadratic_equation(2, 3, 0) print quadratic_equation(1, -6, 5) 这段代码为什么不对,求解
2015-12-19
举报