SCU 2006 warmup contest 19

D: Lucky and Good Months by Gregorian Calendar