Answered step by step
Verified Expert Solution
Question
1 Approved Answer
I am working on a java Blue Jay project and Am struggling with a few parts of my assignment. Here the code I have so
I am working on a java Blue Jay project and Am struggling with a few parts of my assignment.
Here the code I have so far
Constructor that takes a name as its only input parameter and sets the initial balance to zero. - Constructor that takes a name and an initial balance as its two input parameters. - An accessor method that returns the current balance of the account. - An accessor method that returns the current name of the account. - A mutator method that sets the name of the account to the new name in its input parameter. - A mutator method that makes a deposit to the account by adding its input parameter to the balance. - A method that makes a withdrawal from the account by subtracting its input parameter from the balance. - Write your class so that it prohibits negative values for deposit and withdrawal and so that it prohibits a withdrawal of an amount larger than the balance. Test your class thoroughly. Write a description of class BankAccount here. @author (your name) @version (a version number or a date) blic class BankAccount private int balance; private int accountHolder; private String nameStep 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