Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
160794 鸡哥 18高度为k的树 C++ Compile Error 0 MS 0 KB 237 2026-09-26 14:20:23

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int main(){ int a[100],n,x,s=0; cin>>n; for(int i=1;i<=n;i++0){ cin>>a[i]; } cin>>x; for(int i = 1;i<=n;i++){ if(x == a[i]){ s++; } } cout<<s; return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:6:22: error: expected ')' before numeric constant
  for(int i=1;i<=n;i++0){
                      ^
Main.cc:6:23: error: expected ';' before ')' token
  for(int i=1;i<=n;i++0){
                       ^
Main.cc:8:2: warning: statement has no effect [-Wunused-value]
  }
  ^