eachWeekendOfYear

Modified on Thu, 24 Aug 2023

Description

Use this function to obtain all the Saturdays and Sundays in the given year. The result will be in the local timezone.

Syntax

eachWeekendOfYear(year)

Returns

Return ValueDescription
NumberReturns a list of all the weekend dates in the given year.

Sample

ExampleResultDescription
eachWeekendOfYear(2023)There are 104 weekend days in 2023.Returns a list of all the Saturdays and Sundays in the year 2023, totaling 104 weekend days.

To view all the Date functions, click here.

See Also