Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Develop an interactive program thataccepts for each faculty member of a small co

ID: 3613569 • Letter: D

Question

Develop an interactive program thataccepts for each faculty member of a small college two datavalues: faculty salary and a value for faculty performancelevel. The performance level data item can have the values 1,2, and 3 for superior, good, and average, respectively. Wewant the program to compute and display on screen the cost of aproposed pay increase scheme. The pay increase scheme assumesa 3.5 percent across-the-board increase for all faculty members,plus a merit raise. Merit raise percentages depend on theperformance level; for superior performance it is 2.5 percent, forgood performance it is 1.5 percent, and for average performance nomerit raise is given. Test your program on the following dataset:

           Facultysalary             Performance Level

           40000.00                                1

           42500.00                                1

           33500.00                                3

           36700.00                                2

           55000.00                                1

           31000.00                                3

Design your functions so that each is about 3 to 15 lines ofcode after implementation. Express the purpose of each modulein one or two short sentences.

Explanation / Answer

You have repeated you function call twice. I'vehighlighted the lines in red where the function is called twice. Itwould be best to delete the function call inside the Whileloop.
main()
{
   int level;
   double salary, increase, sum;
  
  
   performance_level_data();
  
   salary=faculty_salary();
   while(salary!=0)
   {
      
       salary=faculty_salary(); <--delete this one
       level=faculty_level();
       increase=sum_of_increase(salary, level);
       sum=sum+increase;
       printf(" ");
   }
  
   printf("increase:%lf", sum);
}
hope this helps. Please rate :)