>>> import calendar>>> calendar.monthrange(2010, 1)(4, 31)>>>
calendar.mdays[datetime.date.today().month]