Bank Account help


Error message is…
Lord Noah’s account. Balance: $0.00
Traceback (most recent call last):
File “”, line 28, in
File “”, line 14, in deposit
print “You deposit $%.2f” % (self.amount)
AttributeError: ‘BankAccount’ object has no attribute


I believe your error has to do with how you reference “amount”. It is not an attribute of self, it is a passed parameter. You can see that you correctly reference it as “amount” twice but once you reference it as “self.amount”.



This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.