Write Class Named Employee Following Member Variables Name String Holds Employee Name Idnu Q37144827

Write a class named Employee that has the following membervariables:

  • name A string that holds the employeename
  • idNumber An int to hold employee idnumber
  • department A string to hold the name of thedepartment
  • position A string to hold the jobposition

The class will have three constructors:

1. A constructor that accepts all the internal data such as:

Employee susan(“Susan Meyers”, 47899,”Accounting”, “Vice President”);

2. A constructor that accepts some of the information andassigns an empty string to the missing data such as:

Employee mark(“Mark Jones”,39119);

Then the missing data will be filled in by mutator memberfunctions.

3. A constructor that accepts no information ( the defaultconstructor ) such as:

     

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.