如何在我的Python程序中跟踪错误?

时间:2019-07-24 02:33:54

标签: python-3.x

我已捕获程序错误。这是代码:

Name =input("Enter your name: ")
Address =input("Enter your address: ")
Age =input("Enter your age: ")
Height =(float(input("Enter your height(m): ")*1000))


print ("name : "+Name)
print ("address : "+Address)
print ("age : "+Age)
print ("height : "+str(Height))

1 个答案:

答案 0 :(得分:0)

这是Height作业中的一个小错字,所以:

Name =input("Enter your name: ")
Address =input("Enter your address: ")
Age =input("Enter your age: ")
Height =float(input("Enter your height(m): "))*1000


print ("name : "+Name)
print ("address : "+Address)
print ("age : "+Age)
print ("height : "+str(Height))