# -*- coding: utf-8 -*-
import math
global a,b,c,d
def f(x): return a*math.pow(x,3)+b*math.pow(x,2)+c*x+d
def zzz(gha = float(input("> Gioi han A: ")), ghb = float(input("> Gioi han B: ")), saiso=(ghb-gha)/math.pow(2,20)):
gh=(gha+ghb)/2
if(f(gh)==0 or math.fabs(gha-ghb) < saiso ): return gh
if f(gha)*f(gh)<0: return zzz(gha,gh)
else: return zzz(gh,ghb)
print """
***********************************************************
**CHƯƠNG TRÌNH GIẢI HÀM SỐ BẰNG PHƯƠNG PHÁP TÍNH GẦN ĐÚNG**
***********************************************************
"""
print "Nhập tham số:"
a = float(input("> A:"))
b = float(input("> B:"))
c = float(input("> C:"))
d = float(input("> D:"))
print "Nhap gioi han:"
print zzz()
[/quote]
Đây là đoạn code em viết dùng để giải phương trình gần đúng, khi em biên dịch thì xuất hiện lỗi name ‘ghb’ is not defined, vậy nên khắc phục như thế nào ạ, em xin cảm ơn