Goal: Build a system that simulates a bank account.
- An account has money
- Each account belongs to a person.
- Each account has an account number
- Money can be credited(deposited) into an account
- Money can be debited(withdrawn) from an account .
Build a library that lets a user perform all of the above operations. Primarily, a user(programmer) should be able to require your files and easily do the following:
- Create an account
- Credit money into an account
- Debit money from an account
- Generate the account summary of a given account
- Generate the statement of a given account
The summary should contain:
- Account Number
- Name of the account holder
- The current balance in the account
The statement should contain:
- Account Number
- Name of the account holder
- A list of transactions
Each transaction should contain the type of transaction and the amount
The current balance in the account
Assumptions:
Write tests to verify your work