class documentation

A consumer credit card.

Method __init__ Create a new credit card instance.
Method charge Charge the given price to the card, assuming sufficient credit limit.
Method get_account Return the card's identifying number (typically stored as a string).
Method get_balance Return current balance.
Method get_bank Return the bank's name.
Method get_customer Return name of the customer.
Method get_limit Return current credit limit.
Method make_payment Process customer payment, which reduces balance.
Instance Variable _account Undocumented
Instance Variable _balance Undocumented
Instance Variable _bank Undocumented
Instance Variable _customer Undocumented
Instance Variable _limit Undocumented
def __init__(self, customer, bank, acnt, limit):

Create a new credit card instance.

The initial balance is zero.

customer the name of the customer (e.g., 'John Bowman') bank the name of the bank (e.g., 'California Savings') acnt the acount identifier (e.g., '5391 0375 9387 5309') limit credit limit (measured in dollars)

def charge(self, price):

Charge the given price to the card, assuming sufficient credit limit.

Return True if charge was processed; False if charge was denied.

def get_account(self):

Return the card's identifying number (typically stored as a string).

def get_balance(self):

Return current balance.

def get_bank(self):

Return the bank's name.

def get_customer(self):

Return name of the customer.

def get_limit(self):

Return current credit limit.

def make_payment(self, amount):

Process customer payment, which reduces balance.

_account =

Undocumented

_balance: int =

Undocumented

_bank =

Undocumented

_customer =

Undocumented

_limit =

Undocumented