Answered step by step
Verified Expert Solution
Question
1 Approved Answer
In addition to this code can you also follow these steps. my assignment is the same but adds in two extra classes. Can you please
In addition to this code can you also follow these steps. my assignment is the same but adds in two extra classes. Can you please update this code so it works for my assignment? Class Uniquelnstructortist
jesing ctpal
Uniagelntractorint
ratendo ;Nw ineg, ject
Conatevets Sommary
eviakTisis
Ceestractor and Ceworlyos
Method Sumenary
Figure : Summary of the DewqueluatructerLiat Class.
A defoult coustroctor to initialize inatructorArrayliat:
One getter motbod to return the irsitance variable arovsaoe
A method addInatructor that wdd an instructor into inatructorhrrayLat Malar
sure you only add it if imatructordrrayliat doss not contain this now Instructor
objoct. Otherwise, vou will bot add it to the list.
A method containaInatructor that ss used to chock whether the input irstructor is in
inatroctorArrayliset oe not. Thas motbod may be called within the addIastructor
method.
Note: You really don't have to implement thas moctbod if you dou't want. You can do
the dhecking proress within the addInatroctor method. It maless your implement ation
cksuner if adkling thas moctbod UniqueStudentList class
In the third fike UniqueStudeatliat. jawa, you may imtode the folbwing instabce varlabks
and methods:
Priwate instance varlable atudent &rrayLat type: RrrayLst ctudent s
A defialt constroctoe to imitialize atudeathrrayLst :
Class Uniquestudentust
ins ling Cryct
Unkueltionorint
eatesin ; wwang, pect
Conatructar tommary
Cesstantes
Cowatractor and Descriposos
Method Summary
Figure: : Summary of the UnirgostudentList Class.
One getter mortbod to return the instance varlable arrsooe
A method addStudent that add a student into atudest MrrayLat Mabe sare you only
add it if atudent:ArrayLat does bot coetain thas bew studsut objext. Otherwise, you
will not add it to be list.
A morbod containaStudent that is ued to chock whether the imput student is in
atudemt RryayLat or bot. This method may be calbed within the adagtudeat mothod.
Note: You really don't have to iemplement thas motbod if you doe't want. You can do
the dhecking process within the addgtudeat method. It mabes your implementation
ckoner if adding thas mothool.
Step 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