Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
150004 徐英杰 11下一次奥运会 C++ Accepted 1 MS 280 KB 427 2026-03-21 16:03:12

Tests(10/10):


Code:

#include<iostream> #include<iomanip> using namespace std; int main() { /* *保留n位小数 *printf("%.nlf",a); * *使用cout格式化输出:#include<iomanip> *保留n位小数: *cout<<fixed<<setprecision(n)<<a; * */ int y; cin>>y; if (y <= 2008) { cout<<4 - (2008 - y)%4; }else { cout<<4 - (y -2008 )%4; } return 0; }