/ Vijos /

记录详情

Time Exceeded

foo.cc: In function 'void line_gr::get_line(int*, int*, int*, int, int*, int*, int*, int&)':
foo.cc:53:3: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
   for(int i=1;i<=ct+1;i++)al[i]=0;ct=0;
   ^~~
foo.cc:53:35: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
   for(int i=1;i<=ct+1;i++)al[i]=0;ct=0;
                                   ^~
foo.cc: In function 'll line_gr::calcline4(int*, int)':
foo.cc:74:3: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
   for(int i=1;i<=ct+1;i++)d1[i]=0;for(int i=1;i<=ct;i++)d2[i]=0;return ret;
   ^~~
foo.cc:74:35: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
   for(int i=1;i<=ct+1;i++)d1[i]=0;for(int i=1;i<=ct;i++)d2[i]=0;return ret;
                                   ^~~
foo.cc: In function 'll line_gr::subcalc(tree1&, int)':
foo.cc:78:3: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
   for(int i=1;i<=ct[0]+1;i++)al[0][i]=0;ct[0]=0;
   ^~~
foo.cc:78:41: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
   for(int i=1;i<=ct[0]+1;i++)al[0][i]=0;ct[0]=0;
                                         ^~
foo.cc: In function 'void dfs(int, int)':
foo.cc:102:3: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
   if(ntr.siz[rt]==1)continue;if(son<siz[sub[rt]]){dp[u][rt]=0;continue;}
   ^~
foo.cc:102:30: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
   if(ntr.siz[rt]==1)continue;if(son<siz[sub[rt]]){dp[u][rt]=0;continue;}
                              ^~
foo.cc:103:3: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
   for(int k=sub[rt];k;k=(k-1)&sub[rt])tdp[k]=0;tdp[0]=1;
   ^~~
foo.cc:103:48: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
   for(int k=sub[rt];k;k=(k-1)&sub[rt])tdp[k]=0;tdp[0]=1;
                                                ^~~
foo.cc: In function 'void solve(int, int, int, int)':
foo.cc:124:3: warning: this 'if' clause does not guard... [-Wmisleading-indentation]
   if(cur!=tar)return;tp=0;ntr.clr();
   ^~
foo.cc:124:22: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'if'
   if(cur!=tar)return;tp=0;ntr.clr();
                      ^~
foo.cc: In function 'll calcline3()':
foo.cc:138:2: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
  for(int i=2;i<=ct;i+=2)(ans+=(ll)(d[v[i]]-1)*(d[v[i-1]]-1))%=mod;return ans;
  ^~~
foo.cc:138:67: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
  for(int i=2;i<=ct;i+=2)(ans+=(ll)(d[v[i]]-1)*(d[v[i-1]]-1))%=mod;return ans;
                                                                   ^~~~~~
foo.cc: In function 'int main()':
foo.cc:151:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
  scanf("%d%d",&n,&k);
  ~~~~~^~~~~~~~~~~~~~
foo.cc:152:54: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
  for(int i=1,u,V;i<n;i++)scanf("%d%d",&u,&V),add(u,V),add(V,u);
                          ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~
正在同步测试数据,请稍后
[Hydro](https://hydro.ac)提供评测服务
# 状态 耗时 内存占用
#1 Accepted 3ms 1.453 MiB
#2 Accepted 3ms 1.477 MiB
#3 Accepted 3ms 1.5 MiB
#4 Accepted 15ms 2.035 MiB
#5 Accepted 17ms 2.07 MiB
#6 Accepted 36ms 2.098 MiB
#7 Accepted 83ms 2.121 MiB
#8 Accepted 258ms 3.66 MiB
#9 Time Exceeded ≥3213ms ≥157.473 MiB
#10 Time Exceeded ≥3216ms ≥157.473 MiB

信息

递交者
类型
递交
题目
P2041 线图
语言
C++
递交时间
2021-07-17 14:57:03
评测时间
2021-07-17 14:57:03
评测机
分数
80
总耗时
≥6851ms
峰值内存
≥157.473 MiB