Question: PDE java.pdf + - File | D:/Downloads/java.pdf Not syncing Q 2 of 5 a D Page view | A Read aloud y Draw Highlight Erase

PDE java.pdf + - File | D:/Downloads/java.pdf Not syncing Q 2 of 5 a D Page view | A Read aloud y Draw Highlight Erase Question 1 [40 pts] Implement the below classes and interface as presented in the following UML diagram except the class Basic Subscriber for which you will find the code provided below. For all classes implement only the getters that you will need later in your code. Account Customer # number: int # balance: double +Account (accNum: int, bal: double) +toString(): String +computeInterest(): double -id: int -name: String -accounts: [] Account -accounts Counter: int +Customer: (id: int, name: String) +addAccount (acc: Account) : void +getAccounts(): []Account +toString(): String > Comparable + compareTo (O: E): int Checking Saving +Checking (accNum:int, bal: double) +toString(): String +computeInterest(): double -rate: double -nbYear: int +Saving (accNum: int, bal: double, ra: double, nbYear: int) +toString(): String +computeInterest(): double + compareTo (O:E): int A. [6 pts) Write the abstract class Account as presented in the above UML. a) Write the constructor take as parameter the account number. b) Write the abstract method computeInterest. c) Write the toString() method returns the information about all data members. B. Do not implement the class Checking. The code is: public class Checking extends Account { public Checking (int accNum, double bal) { super (nbAccount, bal); } public String toString() { return "Checking Account: " + super.toString(); } public double computeInterest() { return 0; O Type here to search TOT O 1 WT Desktop ? ENG 8:07 AM 28-Jan-21
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
