Question: a ) Console application is required that has Classes Account and Actuate. Class Account has an integer data field named id for the account, double

a) Console application is required that has Classes Account and Actuate. Class Account has an integer data field named id for the account, double data field named balance for the account, double data field named annualinterestRate that stores the current interest rate ( Assume all accounts have the same interest rate), Date data field named dateCreated that stores the date when the account was created, a procedure named getMonthlyInterestRate 0 that returns the monthly interest rate, a procedure named getMonthlyInterest 0 that returns the monthly interest, an abstract procedure named withdraw that withdraws a specified amount from the account, and an abstract procedure named deposit that deposits a specified amount to the account.
Hint: The method getMonthlyInterest 0 is to return monthly interest, not the interest rate. Monthly interest is balance * monthlyInterestRate and monthlyInterestRate is annualInterestRate /12. Note that annualInterestRate is a percentage, e.g., like 4.5%. You need to divide it by 100.
Class Actuate inherits from Account and has a no-arguments constructor that creates a default account, a constructor that creates an account with the specified id and initial balance, properties for id, balance, and annualInterestRate that ensure each field is not a negative value, a procedure that print account information and a property that make field dateCreated read only.
i) Write code for Class Account.
ii) Write code for Class Actuate.
[6 marks]
a ) Console application is required that has

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 Accounting Questions!