Question
Please update and explain to display the ouput: Here is the Java Code: Here is the Java code to fix: public class Bankacct { private
Please update and explain to display the ouput:
Here is the Java Code:
Here is the Java code to fix:
public class Bankacct {
private String peen; protected double balance; int mons; public Bankacct() { peen=""; balance=0.0; }
public Account(String pIn, double ball) { pEEn = peen; ball = balance; } public void getPEEN(String pen) { pen = peen; } public void setPEEN(String pen) { pen = peen; } public void months(int m) { m=mons; } public void getBal(Double ball) { ball = balance; } }
public class Save extends Bankacct{ double flatfee; double int; public Save() { super(); flatfee = 5.00; int = 0.1; } public Save (String pen, double ball) { super(peen, balance); } public Save (Double ball) { super(); flatfee = 0.10; ball = balance+(balance*flatfee); } public void getBal(String pen) { super.setPEEN(pIn); super.getBal(balance); } public void dep(Double amt) { if (balance 0); } public void wdraw(int amt) { do { balance = balance+(balance*flatfee) - amt-15.00; }while (balance>0); }
public class BankacctTest {
public static void main(String[] args) {
Save Bank = new Save ();
Bank.setPEEN("5555"); Bank.wdraw(50); Bank.dep(1200.2); Bank.wdraw(195.2); Bank.getBalance("5555"); Bank.monthElapsed(1); Bank.getBal("4444"); Bank.getBal("5555"); Bank.monthElapsed(30); Bank.getBal("5555"); }
}
}
You cannot withdraw more money than you have in your savings account! Current balance of your savings account: $1000.00. You need to enter the correct PIN number to check your balance. Current balance of your savings account: $1001.00. Current balance of your savings account: $1031.47Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started