Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

c++ 20 Write a full c++ program to do the following:- 1- define an array (employeeSal) with 5 elements and read them from user. The

image text in transcribed

c++

20 Write a full c++ program to do the following:- 1- define an array (employeeSal) with 5 elements and read them from user. The values in employeeSal array refers to the salaries of 5 employees. 2-define another array(deptids) that corresponds to employeeSal array and store the elements (2,2,1.1.5) in it. The values in deptids array refers to the department ID where each employee works. 3-print the average of all Employee salaries working in deptids 2 4-find the maximum employee salary in deptids 1 5- print the deptids number of the employee with minimum Salary. ex- if the employeeSal array was = (500,300,200,700,100) and deptids = 12 , 2, 1, 1, 5) your output must be: the average for deptid 2 = (500+300)/2=400 the maximum employee salary in deptids 1= 700 the deplds number for minimum employeeSal =5 (10 Points)

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

Recommended Textbook for

The Structure Of The Relational Database Model

Authors: Jan Paredaens ,Paul De Bra ,Marc Gyssens ,Dirk Van Gucht

1st Edition

3642699588, 978-3642699580

More Books

Students also viewed these Databases questions

Question

2. How will the team select a leader?

Answered: 1 week ago