top of page

My HR Employee File


The Employee class contains the following class diagram:

Employee

- fullName : string

- department : int

- payRate : float

+ Employee()

+ Employee(string, int, decimal)

+ getName() : string

+ setName(string) : void

+ getDept() : int

+ setDept(int) : void

+ getPay() : decimal

+ setPay(float) : void

+ PrintData() : string


The class also contains two constructors, as showns above. A default constructor which prompts the user for the new employee information and an overloaded constructor which accepts the employee’s string name, integer department number, and floating number payrate as parameters.

You will write a program that creates two Employee instances, each using a different constructor method to initialize the objects. Department integer values are:

1 - Sales 2 - Marketing 3 - Support 4 - Management 5 - Finance



 
 
 

Recent Posts

See All

Comments


bottom of page