#include<iostream> #include<vector> #include<algorithm> #include<iomanip> #include<string> #include<cmath> using namespace std; int main() { int year; while (cin >> year) { if (year % 400 == 0 || (year % 4 == 0 && year % 100 != 0)) cout << "Leap Year" << endl; else cout << "Not Leap Year" << endl; } } |
Double click to view unformatted code.