Question: In JAVA Create a Bank Account system which includes the following fields and methods Fields: > ID (private, Integer and Unique):ID of the account. >

In JAVA

Create a Bank Account system which includes the following fields and methods

Fields:

> ID (private, Integer and Unique):ID of the account.

> Name (private, String): Name of the owner.

> Saving (private, double): Amount of Money in the account

Methods:

> TransferTo(BankAccount A, double M): Transfer M to B.

> Deposit(double M): Deposit M to the account.

> Withdraw(double M): Withdraw M from the account.

Also need to construct

> Constructor: How to establish objects of each Bank Account.

> Accessor: How to access the private fields of each Bank Account.

> Modifier: How to change the value of private fields.

> toString: How to print the information of the Bank Account.

Bank Account Client

Create three bank accounts, each account has random amount of saving from 0 to 500.

> Save 100 to A.

> Withdraw 1000 from B.

> Transfer 100 from A to C.

> Transfer 1000 from A to B.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!