subject
Business, 12.03.2021 15:30 Dweath50

For this exercise, you will be completing the Account class, which simulates a regular bank account, then using overrides and calls to the superclass to create a StudentAccount. Student accounts differ from regular accounts in that they get a bonus $1 for every deposit, but a $2 fee for every withdrawal. You will override the methods in the StudentAccount by calling the superclass methods with the additonal amount or fee incorporated since the balance is not directly stored in the StudentAccount object. You will also update the toString, as outlined in the comments. When completed, create one student account and one regular account for testing. Deposit and withdraw money and print the results. public class BankTester
{
public static void main(String[] args)
{
// Start here!
}
}
public class Account
{
private String name;
private double balance;
// Initialize values in constructor
public Account(String clientName, double openingBal){
}
// Complete the accessor method
public double getBalance(){
}
// Add amount to balance
public void deposit(double amount){
}
// Subtract amount from balance
public void withdrawal(double amount){
}
// Should read: Regular account with a balance of $__.__
public String toString(){
}
}
public class StudentAccount extends Account
{
// Complete this class with Override methods.
public StudentAccount(String studentName, double openingBal){
}
// Students get a $1 bonus on depositing
// Students pay a $2 fee for withdrawing
// toString() Should read: Student account with a balance of $__.__
}

ansver
Answers: 2

Another question on Business

question
Business, 21.06.2019 15:50
Which result is a positive aspect of globalization?
Answers: 1
question
Business, 21.06.2019 20:30
Abond is issued for less than its face value. which statement most likely would explain why? a. the bond's contract rate is higher than the market rate at the time of the issue. b. the bond's contract rate is the same as the market rate at the time of the issue. c. the bond's contract rate is lower than the market rate at the time of the issue. d. the bond isn't secured by specific assets of the corporation.
Answers: 1
question
Business, 22.06.2019 11:10
Robert black, regional manager for ford in texas and oklahoma, faced a dilemma. the ford f-150 pickup truck was the best-selling pickup ever, yet ford's headquarters in detroit had decided to introduce a completely redesigned f-150. how could mr. black sell both trucks at the same time? he still had "old" f-150s in stock. in his advertising, mr. black referred to the new f-150s as follows: "not a better f-150. just the only truck good enough to be the next f-150." this statement represents ford's of the new f-150.
Answers: 2
question
Business, 22.06.2019 22:20
Which of the following is one disadvantage of renting a place to live compared to buying a home? a. tenants have to pay for all repairs to the building. b. the landlord covers the expenses of maintaining the property. c. residents can't alter their living space without permission. d. rent is generally more than monthly mortgage payments.
Answers: 1
You know the right answer?
For this exercise, you will be completing the Account class, which simulates a regular bank account,...
Questions
question
Mathematics, 22.05.2020 08:01
question
Geography, 22.05.2020 08:01
question
Mathematics, 22.05.2020 08:01
question
Mathematics, 22.05.2020 08:01
question
Mathematics, 22.05.2020 08:01
question
Chemistry, 22.05.2020 08:01
question
English, 22.05.2020 08:01
Questions on the website: 13722363