Imagine you work for a bank and you were asked to create a program that keeps track of the customers' money balance, account numbers and customers' name.
Your program should also have these functionalities:
Get the current balance
Accept a deposit
Process withdrawals
Please note that there is also a 1% transaction fee (of the withdrawal amount) for every withdrawal made from the account.
Create a class named BankAccount with the following contents:
Account number
Name of account holder
Current balance
Inside this class, you are asked to create the following methods:
Constructor methods
getBalance( ): is a getter method that returns the account balance
setName(newName): is a setter method to update the account name (in case of name changes)
processDeposit(money): is a method that accepts a deposit and updates the account balance
processWithdraw(money): is a method that processes a withdrawal and updates the account balance after the 1% transaction fee has been applied as well.
You can test your methods using the attached BankAccountTester Java file. Make sure the method names are as specified.
What to submit: [login to view URL]