how many Friday 13th?

A short Riddler’s riddle on the maximum number of Fridays 13th over a calendar year, of which I found 9 by a dumb exploration :


bi=c(1:31,1:29,1:31,1:30,1:31,1:30,1:31,1:31,1:30,1:31,1:30,1:31)
oy=bi[-60]
for(j in 0:(length(cy<-c(bi,oy,oy,oy))-1)){#any day in quartade
dy=c(cy[(j+1):length(cy)],cy[1:j])
for(i in 0:6){
dz=(i+(1:length(cy)))%%7
if((k<-sum((dz==5)*(cy==13)))>9)print(c(i,j,k))}}

with no change whatsoever when starting another day of the year, including a Friday 13.(since this only gains 13 days!). An example of a quartade (!) with nine such days is the sequence 2012-2015 with 3+2+1+3 occurences….

4 Responses to “how many Friday 13th?”

  1. Just for fun, did you verify that a 28-day Feb doesn’t help (e.g. if such a Feb has Fri-13, then so does March) ?

    • Yes, to account for this I started with every possible weekday over five years in a row. A Friday the 13th happening on a 28 Feb year sees one extra Friday the 13th, but, while beneficial, this only happens at most once over the four years. The solution from The Riddler was also having a maximum of 9 as the maximum, so I am afraid there is not so much variability as one could hope for!

  2. […] article was first published on R – Xi'an's Og, and kindly contributed to R-bloggers]. (You can report issue about the content on this page here) […]

  3. […] by data_admin [This article was first published on R – Xi’an’s Og, and kindly contributed to R-bloggers]. (You can report issue about the content on this page […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.