Working days and due dates: Excel interview question
Invoices due at the end of next month, and the working days a client has to pay: the date task interviewers set, solved with EOMONTH and NETWORKDAYS, plus a sheet that grades yours.
NETWORKDAYS counts the working days between two dates, Monday to Friday, with both dates included and any holidays you list left out. NETWORKDAYS.INTL does the same for any other weekend.
Available in Excel 2007 and later, Excel for the web and Google Sheets; NETWORKDAYS.INTL from Excel 2010=NETWORKDAYS(start_date, end_date, [holidays])| Argument | Required | What it means |
|---|---|---|
start_date | Yes | The first day. It counts if it's a working day. |
end_date | Yes | The last day, which counts too. If it's before start_date, the result is negative. |
holidays | No | A range of dates to leave out, such as public holidays or days the office is closed. Order doesn't matter. |
January 2026 has 31 days, and the weekdays among them are the working days.
| Row | A | B | C |
|---|---|---|---|
| 1 | From | To | Working days |
| 2 | 1 Jan 2026 | 31 Jan 2026 | 22 |
=NETWORKDAYS(A2,B2) → 22The third argument lists days off. All three here fall on weekdays, so each takes one day off the count.
| Row | A | B | C | D | E |
|---|---|---|---|---|---|
| 1 | From | To | Working days | Holidays | |
| 2 | 1 Dec 2026 | 31 Dec 2026 | 20 | 24 Dec 2026 | |
| 3 | 25 Dec 2026 | ||||
| 4 | 31 Dec 2026 |
=NETWORKDAYS(A2,B2,E2:E4) → 20NETWORKDAYS.INTL takes a weekend code as its third argument; 7 means Friday and Saturday off. January 2026 has five Fridays and five Saturdays.
| Row | A | B | C |
|---|---|---|---|
| 1 | From | To | Working days |
| 2 | 1 Jan 2026 | 31 Jan 2026 | 21 |
=NETWORKDAYS.INTL(A2,B2,7) → 21A weekend can also be spelled out day by day, Monday first, with 1 for a day off: "0000001" is Sundays only.
| Row | A | B | C |
|---|---|---|---|
| 1 | From | To | Days open |
| 2 | 1 Jan 2026 | 31 Jan 2026 | 27 |
=NETWORKDAYS.INTL(A2,B2,"0000001") → 27New data, so you can't copy the answer above. We check the number your formula returns, then change the data to make sure it still holds.
Your task: In C2, count the billable days from A2 to B2: Monday to Friday, without the days the office is closed (E2:E4).
Graded live| Row | A | B | C | D | E |
|---|---|---|---|---|---|
| 1 | From | To | Billable days | Closed | |
| 2 | 1 Apr 2026 | 30 Apr 2026 | 3 Apr 2026 | ||
| 3 | 6 Apr 2026 | ||||
| 4 | 25 May 2026 |
Write the formula in the bar above, then press Check or Enter.
NETWORKDAYS takes the first day, the last day and the list of closed days: A2, B2 and E2:E4.
=NETWORKDAYS(A2,B2,E2:E4) Any formula that returns the same result passes.
=NETWORKDAYS.INTL(start_date, end_date, [weekend], [holidays]) works like NETWORKDAYS, with the weekend as its third argument and the holidays moved to the fourth. The weekend is a code:
| Code | Days off |
|---|---|
| 1, or left out | Saturday and Sunday |
| 2 to 7 | Two days in a row, from Sunday and Monday (2) to Friday and Saturday (7) |
| 11 to 17 | One day, from Sunday only (11) to Saturday only (17) |
Or spell the week out in seven characters, one for each day from Monday to Sunday, with 1 for a day off and 0 for a working day: "0000011" is a Saturday and Sunday weekend, and "1000001" gives Sunday and Monday off. WORKDAY has the same codes in WORKDAY.INTL.
Yes, both, when they're working days. A task from Monday to the Friday of the same week is five working days.
=NETWORKDAYS.INTL(A2,B2,7). Weekend code 7 is Friday and Saturday; holidays go in the fourth argument.
The result is negative: the same number of working days, with a minus sign.
Worked problems with practice sheets.
Invoices due at the end of next month, and the working days a client has to pay: the date task interviewers set, solved with EOMONTH and NETWORKDAYS, plus a sheet that grades yours.
Practise NETWORKDAYS and the functions around it in a live grid that grades your result and explains your mistakes.
Runs in your browser · Graded on your result · No install