Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Check if a year is leap year or not
//clang 3.8.0 #include <iostream> using namespace std; int main() { int year; cout << "Enter a year: "; cin >> year; if (year % 4 == 0) { if (year % 100 == 0) { if (year % 400 == 0) cout << year << " is a leap year."; else cout << year << " is not a leap year."; } else cout << year << " is a leap year."; } else cout << year << " is not a leap year."; return 0; }
run
|
edit
|
history
|
help
0
Peregruzka
Recursive Sort Example
Mi primer ejemplo con RexTester colgado en My wall
overloading
ECE2574_Function_Calling_Example
"nearest enclosing namespace"
why
Dat pointers
Vector examples....
tuple, order of members