Skip to content

Instantly share code, notes, and snippets.

View wikkiewikkie's full-sized avatar

wikkiewikkie wikkiewikkie

  • USA
  • 09:59 (UTC -04:00)
View GitHub Profile
@wikkiewikkie
wikkiewikkie / gist:a02673f8acbb5f808e5654754abae7f1
Created December 5, 2016 17:29
Function to get equivalent ISO week and date
def getEquivDate(d, y):
"""Returns the date during another year that has the same ISO week and weekday as the date provided.
Args:
d (datetime.date): The date you want to get the equivalent of.
y (int): The year that you want to get the equivalent date for.
Returns:
datetime.date