请进行测试用例设计:一串数字,闰年的判别
#!/usr/bin/python # -*- coding: utf-8 -*- year = int(input()) if year <= 0 and year > 9999: print("Please enter a proper year.") if year%4 == 0 and year%100 != 0 or year%400 == 0: print("Yes.") else: print("No.")
这道题你会答吗?花几分钟告诉大家答案吧!
扫描二维码,关注牛客网
下载牛客APP,随时随地刷题