Function int readHours() reads one or more hours worked by an employee in the week, computes their sum and returns it. The list of hours is terminated by the dummy value -99. Function main calls the function 3 times with input values and then prints the total number of hours
Im not getting a value returned after inputting a value, anyone see any mistakes ?
PS I know you were calling the function three times and maybe you have special reason but remember that the dummy value allows any number of inputs, so a user would get sick of typing in -99. There are also problems if you wanted a grand total of the three.