Complete the BankTransactions program that applies a series of transactions to bank accounts.
Its main() method uses the Bank class to manage the ArrayList of BankAccount objects.
It uses the readBankAcounts() method to read accounts from the accounts file as account number and balance values from a text file, and creates a BankAccount object and inserts the new bank account into the Bank. The accounts.txt file could contain lines like:
1001 10000.00
1012 2830.45
1027 3389.21
Then, it uses the applyTransactions() method to read transaction lines from the transactions file as an action ("deposit", "withdraw", or "transfer"), followed by the account(s) and amount for the transaction. The deposit and withdraw actions are followed by one account number and then the amount. The transfer action is followed by the account to transfer from, the account to transfer to, and the amount to transfer. The transactions.txt file could contain lines like:
deposit 1001 100.00
transfer 1012 1001 100.00
withdraw 1012 50.00
When the program is finished, it prints the list of all the accounts and balances, like:
1001 10200.00
1012 2680.45
1027 3389.21
You will need to complete the readBankAccounts() and applyTransactions() methods in the BankTransactions.java class.
Test your program using the provided accounts.txt and transactions.txt files, but be aware that we will test your program using different accounts and transactions files.