Question: Create a Java console banking application Features Deposit Deposit money into the account Withdraw Take money out of the account Balance Show the balance of
Create a Java console banking application
FeaturesDeposit
Deposit money into the account
Withdraw
Take money out of the account
Balance
Show the balance of the account
Report
Includes deposits, withdrawals
Exit
Once you exit, all data is gone
No need to save any data
Use Eclipse
The project should be called Assignment1
Apart from the main class, you should have
BankAccount class to deal with the banking logic and storage
Menu class to create and interact with the menu choices
Use encapsulation (getters/setters) for the fields
Comment thoroughly!
No bank logic should be in the main class or Menu class
No menu logic should be in the main class or BankAccount
SAMPLE OUTPUT
MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: abc "abc" is an invalid choice MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: 2 You have no money in the account! MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: 1 Deposit amount: xyz "abc" is invalid. MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: 1 Deposit amount: 10 Thank you. MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: 3 Current balance: $10.50 MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: 2 Withdraw amount: 15 You only have $10.50 in the account MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: 2 Withdraw amount: 7.25 Take your $7.25 MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: 3 Current balance: $3.25 MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: 4 2018-10-21 16:15:59 +$10.50 2018-10-21 16:16:23 -$7.25 Current balance: $3.25 MENU 1) Deposit 2) Withdraw 3) Balance 4) Report 5) Exit Choice: 5 Goodbye
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
