python判断闰年和平年

python判断闰年和平年

l=int(input('请输入一个年份'))
if l%100!=0 and l%4==0:
    print('闰年')
elif l%400==0:
    print('闰年')
else :
    print('平年')

发布了10 篇原创文章 · 获赞 0 · 访问量 53

猜你喜欢

转载自blog.csdn.net/weixin_44220805/article/details/105305932