@staticmethod<EOL><INDENT>def get_last_weekday_in_month(year, month, weekday):<DEDENT>
day = date(year, month, monthrange(year, month)[<NUM_LIT:1>])<EOL>while True:<EOL><INDENT>if day.weekday() == weekday:<EOL><INDENT>break<EOL><DEDENT>day = day - timedelta(days=<NUM_LIT:1>)<EOL><DEDENT>return day<EOL>
Get the last weekday in a given month. e.g:

        >>> # the last monday in Jan 2013
        >>> Calendar.get_last_weekday_in_month(2013, 1, MON)
        datetime.date(2013, 1, 28)