Due March 13, 1999 at the beginning of class.
Please turn in your source code and an example print run from Part B.
Expand the BankAccount object to also store a password (with getters and setters).
Make a bank object that holds up to 200 accounts in an array.
Provide the following functions for the bank:
Note that when you have no accounts, each slot in the array will be contain 'null', and not an actual BankAccount object. You will have to test for this if you don't keep track of how many BankAccounts you have at any given time.
Requires a name, password, and initial balance: the bank can supply the interest rate.
Requires a name.
Returns a reference to the BankAccount object which has the given name.
Requires a name and a password.
Should use the findAccountByName function.
Returns a reference to the BankAccount with the given name if the password is correct.
Returns the total amount of interest the bank paid out.
Returns the average balance of the accounts in the bank.
Returns the median (middle) balance of the accounts.
Returns the lowest balance.
Returns the highest balance.
Create a main that adds a bunch of accounts (at least four or five) to the bank, runs monthly updates for a few years (complaining about the interest it's paying out each month), and giving the bank statistics at the beginning and end of the two year time period.
The views and opinions expressed in this page are strictly those of the page author.
The contents of this page have not been reviewed or approved by the University of Minnesota.