Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
5588 | 高振轩 | 闰年的数量 | C++ | Accepted | 0 MS | 260 KB | 224 | 2024-11-30 15:24:19 |
#include<bits/stdc++.h> using namespace std; int s(int x,int y){ int z=0; for(int i=x;i<=y;i++){ if(i%4==0&&i%100!=0||i%400==0){ z++; } }return z; } int main(){ int a,b; cin>>a>>b; cout<<s(a,b); }