In Class: Week 12: Wednesday


I want you to grab new copies of all the files you copied over on Monday. If you modified your recursivelist.py file on Monday, just answer 'n' when cp asks if you want to overwrite recursivelist.py:

    $ cd 
    $ cd cs21/class/week12
    $ pwd
      /home/your_user_name/cs21/class/week12
    
    $ cp cp ~newhall/public/cs21/week12/* .
    cp: overwrite `./account.py'? y
    cp: overwrite `./acct_data.txt'? y
    cp: overwrite `./atm.py'? y
    cp: overwrite `./recursivelist.py'? n
If you didn't create a week12 directory on Monday, do that first before copying over the files:
    $ cd 
    $ cd cs21/class
    $ pwd
      /home/your_user_name/cs21/class
    $ mkdir week12       

    $ cd week12
    $ pwd
      /home/your_user_name/cs21/class/week12

We are going to do some of the following together:
  1. open account.py and look at the partial implementation of the Account class. We will add some of its missing methods.

  2. open test_account.py. This file imports the Account class creates some account objects and invokes some of its methods. We can use this to test additional method of the Account class.

  3. open atm.py. This file contain an example of creating a list of Account objects. We will try some things out in here. Next week we will re-visit some of this in a different context.

    This is the start of a not-very-secure ATM program.

    Parts of the program are complete, but other parts are left for you to do.

    At first a list of Account objects is created by the program, and we will try some things out on this list.

    Later we will create a list of Account objects by reading in the bank account data base is stored in a file.

    We may complete some of the missing functionality that operates on this list of Account objects. Add and test in this order: