| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 145127 | 姜景文 | 判断闰年I | C++ | Compile Error | 0 MS | 0 KB | 343 | 2026-01-25 08:56:11 |
#include<bits/stdc++.h> using namespace std; int main(){ int t, n; cin>>t; for(int i=0;i<t;i++){ cin>>n; } for(int i=0;i<t;i++){ if(n%100!=0 && n%4==0|| n%400==0){ cout<<""leap year"; }else { cout<<"not leap year"; } } return 0; }
Main.cc:11:30: warning: missing terminating " character
cout<<""leap year";
^
Main.cc:11:13: error: missing terminating " character
cout<<""leap year";
^
Main.cc: In function 'int main()':
Main.cc:10:23: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
if(n%100!=0 && n%4==0|| n%400==0){
^
Main.cc:11:19: error: unable to find string literal operator 'operator""leap' with 'const char [1]', 'long unsigned int' arguments
cout<<""leap year";
^