code: def match_date(date, date_pattern):
      
      # unpack the date and pattern
      year, month, day, day_of_week = date
      year_p, month_p, day_p, day_of_week_p = date_pattern
  
      # check the year
      if year_p == 255:
          # any year
          pass
      elif year != year_p:
          # specific year
          return False
  
      # check the month
      if month_p == 255:
          # any month
          pass
      elif month_p == 13:
          # odd months
          if (month % 2) == 0:
              return False
      elif month_p == 14:
          # even months
          if (month % 2) == 1:
              return False
      elif month != month_p:
          # specific month
          return False
  
      # check the day
      if day_p == 255:
          # any day
          pass
      elif day_p == 32:
          # last day of the month
          last_day = calendar.monthrange(year + 1900, month)[1]
          if day != last_day:
              return False
      elif day_p == 33:
          # odd days of the month
          if (day % 2) == 0:
              return False
      elif day_p == 34:
          # even days of the month
          if (day % 2) == 1:
              return False
      elif day != day_p:
          # specific day
          return False
  
      # check the day of week
      if day_of_week_p == 255:
          # any day of the week
          pass
      elif day_of_week != day_of_week_p:
          # specific day of the week
          return False
  
      # all tests pass
      return True
docs: Match a specific date, a four-tuple with no special values, with a date
      pattern, four-tuple possibly having special values.