$ jq -r -n -f Five_Weekends.jq There are 201 months with 5 weekends from 1900 to 2100 inclusive; the first and last five are as follows: Mar 1901 Aug 1902 May 1903 Jan 1904 Jul 1904 ... Mar 2097 Aug 2098 May 2099 Jan 2100 Oct 2100 In this period, there are 29 years which have no five-weekend months.