Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1. BankAccount java public class BankAccount Represents a basic bank account. fi

ID: 3785922 • Letter: 1

Question

1. BankAccount java public class BankAccount Represents a basic bank account. finals: As mentioned above, declare and use in place of literal constants as needed. Fields: 3 private fields for the customer's name, account balance, and the interest rate (String, double, double and use correct naming conventions). 2 protected fields (driver program needs direct access) for myMonthlyWithdrawCount and myMonthlyServiceCharges (int, double). Methods: public BankAccount (final String theNameofowner, final double thelnterestRate) The constructor initializes the name and interest rate to the values of the passed parameters (taking care that the interest rate is a legitimate value) and sets the remaining fields to 0. public double getBalance() Returns the current balance

Explanation / Answer

Solution:

/** BankAccount.java **/