Answer
See explanation
Work Step by Step
The leap year must be divisible by 4, but it should not be the end of century year (like 2100) unless the end of century year is divisible by 400.
year = take input
if (year % 4==0) and (year % 100 !=0 or year % 400 == 0):
print("Yes the given year is a leap year")
else:
print("The given year is not a leap year")