http://qs321.pair.com?node_id=1091760


in reply to Gettting the last Friday of every month using Time::Piece

From the Introduction to the Wikipedia article titled Determination of the day of the week:

The basic approach of nearly all of the methods to calculate the day of the week begins by starting from an ‘anchor date’: a known pair (such as January 1, 1800 as a Wednesday), determining the number of days between the known day and the day that you are trying to determine, and using arithmetic modulo 7 to find a new numerical day of the week.
  • Comment on Re: Gettting the last Friday of every month using Time::Piece