The checking account charges ustomers a fixed service charge of $25.00 per month. The savings account yields a fixed interest rate of 3% per year on the monthly balance. The bank allows cutomers to make deposits, withdrawals, and to get their balance at any time.
From the set of responses below select those that best describe an interface for this situation.
(I) (II)
public interface Banking public interface Banking
{ {
double CHECKING_RATE = 25.0; double CHECKING_RATE = 25.0;
final double SAVING_RATE = 0.03; double SAVING_RATE = 0.03;
void deposit(double amount); void deposit(double amount);
double withdraw(double amount); double withdraw(double amount);
double getBalance(); static double money = getBalance();
} }
(III) (IV)
public interface Bankikng public interface Banking
{ {
static double CHECKING_RATE = 25.0; double CHECKING_RATE = 25.0;
double SAVING_RATE = 0.03; double SAVING_RATE = 0.03;
void deposit(double amount); void deposit(double amount);
abstract double withdraw(double amount); double withdraw(double amount);
double getBalance(); static double getBalance(){ return amo
Comments
Content
The checking account charges ustomers a fixed service charge of $25.00 per month. The savings account yields a fixed interest rate of 3% per year on the monthly balance. The bank allows cutomers to make deposits, withdrawals, and to get their balance at any time.
From the set of responses below select those that best describe an interface for this situation.
(I) (II)
public interface Banking public interface Banking
{ {
double CHECKING_RATE = 25.0; double CHECKING_RATE = 25.0;
final double SAVING_RATE = 0.03; double SAVING_RATE = 0.03;
void deposit(double amount); void deposit(double amount);
double withdraw(double amount); double withdraw(double amount);
double getBalance(); static double money = getBalance();
} }
(III) (IV)
public interface Bankikng public interface Banking
{ {
static double CHECKING_RATE = 25.0; double CHECKING_RATE = 25.0;
double SAVING_RATE = 0.03; double SAVING_RATE = 0.03;
void deposit(double amount); void deposit(double amount);
abstract double withdraw(double amount); double withdraw(double amount);
double getBalance(); static double getBalance(){ return amo