Created
April 18, 2022 13:16
-
-
Save eimon96/e74b3d6852ad33342974e9165946410c to your computer and use it in GitHub Desktop.
2020
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
int handleExit(); | |
int main() | |
{ | |
int year; | |
cout << "Hellooo! Lets do this...\nYear:"; | |
cin >> year; | |
if (year%4 == 0 && year%100 != 0) | |
{ | |
cout << "Leap Year!"; | |
} | |
else if (year%400==0) | |
{ | |
cout << "Leap Year!"; | |
} | |
else | |
{ | |
cout << "Just a Common Year"; | |
}; | |
cout << "\nHappy 29/2/20 xDD"; | |
handleExit(); | |
}; | |
int handleExit() | |
{ | |
cout << "\nPress enter to exit."; | |
cin.get(); | |
if (cin.get() == '\n') | |
{ | |
return 0; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment