Python method for determining flat years and leap years

Python method for determining flat years and leap years

testYear = 2022
if (testYear % 4 = 0 and testYear % 100 != 0) or testYear % 400 == 0:
	print("flat")
else:
	print("leap")

Comments

Popular posts from this blog

Python Receiving and parse JSON Data via UDP protocol

ubus lua client method and event registration code demo/example