Recall the Account definition methods.
public class BankFunctions {
public static double totalAssets(Bank bank) {
}
}
public class BankFunctions {
public static double totalAssets(Bank bank) {
double ret = 0.0;
for(int i = 0; i < bank.getNumAccounts(); i++) {
ret += bank.getAccount(i).getBalance();
}
return ret;
}
}