This is my first time creating a program using void functions. The program allows a user to enter an employees hours and pay rate to calculate gross pay. In the end, the program should display the total gross pay for all of the employees. However, my program displays the total gross pay for all employees as 0. Please help.
Roson, all is supposed to be the total gross pay for all of the employees. gPay is supposed to be a parameter for pay in the calcGrossPay function, and grossPay is supposed to be a parameter for pay in the getTotalPay function. Sorry if it's confusing, I'm having trouble understanding void functions AND value returning functions.
jlb, so should I change the getTotalPay function? I'm not exactly sure what to do.