Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
145096 姜景文 [在线测评解答教程] 闰年 C++ Compile Error 0 MS 0 KB 261 2026-01-25 08:33:08

Tests(0/0):


Code:

#include <stdio.h> using namespace std; int main() { int t, n; cin>>t; for(int i=0;i<t;i++){ cin>>n; if(n%100!=0 && n%4==0|| n%400==0) cout<<"Yes"; else cout<<"No"; } return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:6:4: error: 'cin' was not declared in this scope
    cin>>t;
    ^
Main.cc:9:22: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
         if(n%100!=0  && n%4==0|| n%400==0)
                      ^
Main.cc:10:13: error: 'cout' was not declared in this scope
             cout<<"Yes";
             ^
Main.cc:12:13: error: 'cout' was not declared in this scope
             cout<<"No";
             ^