Returns the day of the week for a given date.

**Sample Usage**

WEEKDAY("7/9/2019")

WEEKDAY(C5)

**Syntax**

WEEKDAY(date, [type])

- date - The date for which to determine the day of the week.

- type - [OPTIONAL] A number indicating which numbering system to use to represent weekdays.

**Examples**

WEEKDAY("7/9/2019") returns 3, which represents the day of the week corresponding to the given date (Tuesday).

WEEKDAY(C5) returns the day of the week that the date value in C5 falls on.

**Notes**

- If type is left unspecified or is set to 1, Sunday marks the start of a week and the value of Sunday is 1, therefore the value of Saturday is 7.
- If type is set to 2, Monday marks the start of the week and the value of Monday is 1, therefore the value of Sunday is 7.
- If type is set to 3, Monday marks the start of the week and the value of Monday is 0, therefore the value of Sunday is 6.