Problem:

Listed in columns A & B are the times an employee signed in and out of work each day.

Column C contains the rate per hour for that particular day.

We want to calculate the employee’s total pay.

Solution 1:

To calculate the number of hours worked per day, enter the following formula in column D:

=B2-A2+(A2>B2)

Then calculate the pay per day by entering the following formula in column E:

=C2*D2*24

Finally, use the SUM function as shown in the following formula to sum the results from column E:

=SUM(E2:E7)

What is the meaning of (A2>B2) in the first equation?