import datetime import sys class Date : """A way to keep Mike's stupid psudo-Proleptic Gregorian date count on his blog from destroying all of Western Civilization and our way of life""" def __init__(self, curYear,ordDate) : minYear = datetime.date(curYear,1,1) """Convert to Ordinal""" minYear = datetime.date.toordinal(minYear) self.minYear = minYear self.ordDate = ordDate def printGodsIntendedDate(self) : """Does the Calculation and returns the One True Date""" goodDate = self.minYear + self.ordDate - 1 "Had to subtract by 1 because his date function treats 1-1-xxxx as 0" returnDate = datetime.date.fromordinal(goodDate) return returnDate