how to check leap year in php 3f

Solutions on MaxInterview for how to check leap year in php 3f by the best coders in the world

showing results for - "how to check leap year in php 3f"
Emma
31 Jun 2017
1$year = 2014;
2// Leap years are divisible by 400 or by 4 but not 100
3if(($year % 400 == 0) || (($year % 100 == 0) && ($year % 4 == 0))){
4    echo "$year is a leap year.";
5} else{
6    echo "$year is normal year.";
7}
8