/ Vijos /

记录详情

Compile Error

/in/foo.cc:1:20: warning: extra tokens at end of #include directive
 #include <iostream>;
                    ^
/in/foo.cc: In function 'int main()':
/in/foo.cc:5:6: error: expected ';' before 'long'
  max long int n,m=0,i,j;bool l[10^200];
      ^~~~
/in/foo.cc:5:24: error: statement cannot resolve address of overloaded function
  max long int n,m=0,i,j;bool l[10^200];
                        ^
/in/foo.cc:6:7: error: 'n' was not declared in this scope
  cin>>n;
       ^
/in/foo.cc:7:6: error: 'i' was not declared in this scope
  for(i=0;i<n;i++) l[i]=false;
      ^
/in/foo.cc:8:6: error: 'i' was not declared in this scope
  for(i=1;i<=n;i++) for(j=1;j<=n;j++) if(j%i==0) if(l[j-1]==true) l[j-1]=false;else l[j-1]=true;
      ^
/in/foo.cc:8:24: error: 'j' was not declared in this scope
  for(i=1;i<=n;i++) for(j=1;j<=n;j++) if(j%i==0) if(l[j-1]==true) l[j-1]=false;else l[j-1]=true;
                        ^
/in/foo.cc:8:40: warning: suggest explicit braces to avoid ambiguous 'else' [-Wparentheses]
  for(i=1;i<=n;i++) for(j=1;j<=n;j++) if(j%i==0) if(l[j-1]==true) l[j-1]=false;else l[j-1]=true;
                                        ^
/in/foo.cc:9:6: error: 'i' was not declared in this scope
  for(i=0;i<n;i++) if(l[i]) m++;
      ^
/in/foo.cc:9:28: error: 'm' was not declared in this scope
  for(i=0;i<n;i++) if(l[i]) m++;
                            ^
/in/foo.cc:10:8: error: 'm' was not declared in this scope
  cout<<m;
        ^

信息

递交者
类型
递交
题目
P1447 开关灯泡
语言
C++
递交时间
2019-07-23 19:46:17
评测时间
2019-07-23 19:46:17
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes