Run ID | Author | Problem | Lang | Verdict | Time | Memory | Code Length | Submit Time |
---|---|---|---|---|---|---|---|---|
11723 | huangshengxuan | [在线测评解答教程] 闰年 | C++ | Wrong Answer | 0 MS | 248 KB | 360 | 2023-03-15 19:18:25 |
#include<iostream> using namespace std; int main() { int year; cout<<"请输入年份:"; cin>>year; if(year%4==0){ if(year%100==0){ if(year%400==0){ cout<<year<<"是闰年"; } else{cout<<year<<"不是闰年"; } } else { cout<<year<<"是闰年"; } } else{ cout<<year<<"不是闰年"; } return 0; }