Question: Given the C++ statements as below #include using namespace std; int main() { const int NO EMP = 5; double salary [NO_EMP]; double highest =

Given the C++ statements as below

Given the C++ statements as below #include using namespace std; int main()

#include using namespace std; int main() { const int NO EMP = 5; double salary [NO_EMP]; double highest = 0; double sum = 0; // COMPLETE YOUR CODE HERE return 0; Complete the C++ program by prompting a user for 5 employee's salary and store into an array salary. Then display the total of salary as well as the highest salary among the employee. Correct your display to 2 decimal places. [4 marks] Sample Output : Enter salary employee #1 : 2300.50 Enter salary employee #2 : 3700.00 Enter salary employee #3 : 4820.70 Enter salary employee #4 : 1800.00 Enter salary employee #5 : 2330.60 The sum is : RM 14951.80 The highest salary is RM 4820.70

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!