Some consider Friday the 13th (any Friday that falls on the 13th day of a month) unlucky.

In a calendar year, how many Friday the 13th can occur? Find both the minimum and maximum.

#### Solution

Friday the 13th must occur at least one each year, and at most three times.

- Start by figuring out how many days are between the beginning of the year and the 13th of every month.
- January 13 is the 13th day of the year, February 13 is the 44th day, etc.
- We get 13, 44, 72, 103, 133, 164, 194, 225, 256, 286, 317, and 347 for normal years
- And 13, 44, 73, 104, 134, 165, 195, 226, 257, 287, 318, and 348 for leap years

- The key is recognizing that if the difference between the 13th of two months is divisible by 7, then they fall on the same day of the week.
- For example, in a normal year, February 13 is the 44th day of the year and March 13th is the 72nd day of the year. That means there are 28 days between them, or exactly 4 weeks. So if February 13 is a Friday one year, March 13th must also be a Friday.
- The way to easily visualize if the differences are multiples of 7 is to divide the numbers by 7 and look at the remainders. If they have the same remainders, the days between them must be a multiple of 7.
- Also, with this method, each remainder represents a day of the week (relative to the beginning of the year – so if December 31 was a Sunday, a date with a remainder of 6 would be a Saturday and a date with a remainder of 2 would be a Tuesday).
- We get remainders of 6, 2, 2, 5, 0, 3, 5, 1, 4, 6, 2, and 4 for January-December, respectively, for normal years
- And 6, 2, 3, 6, 1, 4, 6, 2, 5, 0, 3, and 5 for leap years

- All possible days of the week (0-6) show up at least once among the remainders, even in leap years, so there must be at least one Friday the 13th every year.
- The most common remainder appears at most three times (February, March, and December all have remainder of 2), even in leap years (January, April, and July all have remainder of 6), so there can be at most three Friday the 13th each year.

wtf is this explanation bro

Hmm, you’re right, the explanation is a bit dense. I tried rewriting and expanding the explanation to make it easier to understand. Hope this is better!