/* University College London Physics Dept Course in C/C++ 3C59 | all rights reserved 2000 | | Example: BankAccount class | | Simple program to demonstrate the use of the BankAccount class | | The user of BankAccount (i.e. this program) is not allowed to know | anything about the innerds of BankAccount, and may only interact | with it throught the "Methods" which have been supplied. | | Author: P.Clarke */ #include "BankAccount_inline.h" int main() { // Make some bank account instances BankAccount goodCustomer ; BankAccount badCustomer ; // Initialise them goodCustomer.initialise( "Peter Clarke", 500.0, 1000.0 ) ; badCustomer.initialise( "Joe Bloggs", -5000.0, 1000.0 ) ; // print out the currently available funds in each goodCustomer.printStatus( ) ; badCustomer.printStatus( ) ; // Deposit some money goodCustomer.deposit( 3000. ) ; // print out new status: goodCustomer.printStatus( ) ; return 1 ; }