Write a program that determines if a year is a leap year. A year is a leap year if divisible by 4, except years divisible by 100 unless also divisible by 400. Read an int for the year.
Use if ((year % 4 == 0 && year % 100 != 0) || (year % 400 == 0)) to combine the rules. Print the result. Test with 2000 (leap), 1900 (not leap), and 2024 (leap). This problem shows how operators combine to solve real-world rules.