Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

3. See the UML diagram for a class Employee, inside this class, method work(ind) takes number of hours this employee works and return a string

image text in transcribed
3. See the UML diagram for a class Employee, inside this class, method work(ind) takes number of hours this employee works and return a string similar to "John works 40 hours per week". We want to extend this class to represent a Faculty class, each faculty is an Employee. Other than the name, age, each faculty also has an instance variable depr (String ) which represents his/her department, also each faculty works differently from a common employee, when call the work in ) method, it will return a string similar to "John do research 20 hours per week". According to the description, finish the UML diagram and write the complete class for Faculty (4 pts) Employee name: string Hage: int +Employee(String, int) work(int): String .toString(): String Faculty Faculty

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Seven NoSQL Databases In A Week Get Up And Running With The Fundamentals And Functionalities Of Seven Of The Most Popular NoSQL Databases

Authors: Aaron Ploetz ,Devram Kandhare ,Sudarshan Kadambi ,Xun Wu

1st Edition

1787288862, 978-1787288867

More Books

Students also viewed these Databases questions