狗都会
2025-07-12 12:56:45
发布于:广东
1阅读
0回复
0点赞
#include<bits/stdc++.h>
using namespace std;
int is_leap(int y){
if(y%4 == 0 && y%100 != 0 || y%400 == 0){
return true;
}else{
return false;
}
}
int main() {
int year;
cin>>year;
if(is_leap(year)==true)cout<<"YES"<<endl;
else cout<<"NO"<<endl;
return 0;
}
这里空空如也
有帮助,赞一个