题解 | #获得月份天数#
获得月份天数
https://www.nowcoder.com/practice/13aeae34f8ed4697960f7cfc80f9f7f6
while True: try: y,m=map(int,input().split()) if y%4==0 and y%100!=0 or y%400==0: if m in [1,3,5,7,8,10,12]: print(31) elif m in [4,6,9,11]: print(30) else: print(29) else: if m in [1,3,5,7,8,10,12]: print(31) elif m in [4,6,9,11]: print(30) else: print(28) except: break