# One way to track attendance using Excel formula

This tutorial shows b.asic attendance tracking formula in Excel

One way to track attendance is with simple formulas based on the COUNTIF function.

## Formula

=COUNTIF(range,"x")

## Explanation

In the example shown, the formula in M5 is:

=COUNTIF(C5:L5,"x")

### How this formula works

This formula simply uses COUNTIF with a criteria of “x” (not quotation marks) to count x’s in each row, where “x” represents “present” and an empty cell represents “absent”:

=COUNTIF(C5:L5,"x") // count present

The count absent days, the worksheet uses COUNTIF again, configured to count empty cells:

=COUNTIF(C5:L5,"") // count absent