Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In this program, you will manage employees in a company. You will design a C++ class called Employee. Objects of employee class have 5 attributes

image text in transcribed
image text in transcribed
image text in transcribed
image text in transcribed
In this program, you will manage employees in a company. You will design a C++ class called Employee. Objects of employee class have 5 attributes such as Employee ID, Employee Name, Department ID, Department Name, and Salary. In your Employee class, you should declare the member variables private. You will implement set/get functions for each attribute Also, you should have at least one constructor function. Finally, it would be helpful if you have a public print0 function to print the employee info on the screen. Once your class is ready, you will read the employees.txt file, which includes all employees in the company. A sample view of the file is given below 100 1 Kasimir 4 Marketing 145000 2 Iona 2 RD 37000 3 Iliana 1 Production 141000 4 Gage 1 Production 64000 5 Ira 4 Marketing 121000 6 Cameron 3 Purchasing 137000 7 Xander 3 Purchasing 125000 8 Amal 2 RD 72000 9 Lamar 2 RD 125000 10 Daniel 4 Marketing 59000 11 Petra 2 RD 43000 12 Alec 5 HR 57000 13 Lewis 5 HR 94000 t in the The first line of the file shows how many employees exis company. After reading this file, you will dynamically allocate an array of employees for that exact number. The employees.txt file may be in different size. It does not have to be 100 as shown above example Starting from the second line, each line contains a single employee information. You can read the rest of the file using a while loop. In each iteration, you wl fill one element of the employee array Once your employee array is ready, you will provide following operations to the user in a menu. 1) Print All Employees a. Print al information of all Employees 2) Print By Department a. Get an input from the user (department ID) b. Print al information only for employees in that 3) Print By Salary

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

Step: 3

blur-text-image

Ace Your Homework with AI

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

Get Started

Students also viewed these Databases questions

Question

How is slaked lime powder prepared ?

Answered: 1 week ago

Question

Why does electric current flow through acid?

Answered: 1 week ago

Question

What is Taxonomy ?

Answered: 1 week ago

Question

1. In taxonomy which are the factors to be studied ?

Answered: 1 week ago

Question

Explain the function and purpose of the Job Level Table.

Answered: 1 week ago