Question: Need this in Java CSC 1351 Fall 2018, Lab 4 Name this project StatisticsDemo Tproject naned StatisticsDemo that i1lustrates the use of interfaces. Create This
CSC 1351 Fall 2018, Lab 4 Name this project StatisticsDemo Tproject naned StatisticsDemo that i1lustrates the use of interfaces. Create This a project will have the tollowing 1) An interface named Measurables with the following abstract methods public int getFiretInt public int getsecondInt) public int getThirdInt O public double getDouble O 2) A class named Student that implements the Measurables and comparable interfaces. The student class will have the following a) Instance variables: private String name: private int examli private int exam2 private int finalExam private double courseGradei b) A constructor with four input parameters that give the values of name examl, exam2, and finalExam. The construetor does not have an input variable for the value of courseGrade. Instead, the constructor wil calculate courseGrade as the average of examl, exam2, and finalExam c) Methods: public int getFirstInt) // returns examl public int getsecondInt O //returns exam2 public int getThirdInt) // returns finalExam public double getDouble) // returns courserade public int compareTo (objec t otherobject) // compares two Student obje // by courseGrade public string tostring) // defines a string to print a student obje // as shown in the output
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
