F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_32170593_24336.cpp:5:19: error: expected ']' before ';' token
 #define maxn 50050;
                   ^
0_0_32170593_24336.cpp:7:8: note: in expansion of macro 'maxn'
 int to[maxn*2],last[maxn*2],val[maxn*2];
        ^
0_0_32170593_24336.cpp:7:13: error: expected unqualified-id before numeric constant
 int to[maxn*2],last[maxn*2],val[maxn*2];
             ^
0_0_32170593_24336.cpp:7:13: error: expected constructor, destructor, or type conversion before numeric constant
0_0_32170593_24336.cpp:7:26: error: expected unqualified-id before numeric constant
 int to[maxn*2],last[maxn*2],val[maxn*2];
                          ^
0_0_32170593_24336.cpp:7:26: error: expected constructor, destructor, or type conversion before numeric constant
0_0_32170593_24336.cpp:7:38: error: expected unqualified-id before numeric constant
 int to[maxn*2],last[maxn*2],val[maxn*2];
                                      ^
0_0_32170593_24336.cpp:7:38: error: expected constructor, destructor, or type conversion before numeric constant
0_0_32170593_24336.cpp:5:19: error: expected ']' before ';' token
 #define maxn 50050;
                   ^
0_0_32170593_24336.cpp:8:14: note: in expansion of macro 'maxn'
 int tot,head[maxn],dep[maxn],dis[maxn],f[maxn],fa[maxn][15];
              ^
0_0_32170593_24336.cpp:8:18: error: expected unqualified-id before ']' token
 int tot,head[maxn],dep[maxn],dis[maxn],f[maxn],fa[maxn][15];
                  ^
0_0_32170593_24336.cpp:8:28: error: expected unqualified-id before ']' token
 int tot,head[maxn],dep[maxn],dis[maxn],f[maxn],fa[maxn][15];
                            ^
0_0_32170593_24336.cpp:8:38: error: expected unqualified-id before ']' token
 int tot,head[maxn],dep[maxn],dis[maxn],f[maxn],fa[maxn][15];
                                      ^
0_0_32170593_24336.cpp:8:46: error: expected unqualified-id before ']' token
 int tot,head[maxn],dep[maxn],dis[maxn],f[maxn],fa[maxn][15];
                                              ^
0_0_32170593_24336.cpp:8:55: error: expected unqualified-id before ']' token
 int tot,head[maxn],dep[maxn],dis[maxn],f[maxn],fa[maxn][15];
                                                       ^
0_0_32170593_24336.cpp:5:19: error: expected ']' before ';' token
 #define maxn 50050;
                   ^
0_0_32170593_24336.cpp:10:10: note: in expansion of macro 'maxn'
 bool vis[maxn];
          ^
0_0_32170593_24336.cpp:10:14: error: expected unqualified-id before ']' token
 bool vis[maxn];
              ^
0_0_32170593_24336.cpp: In function 'int find(int)':
0_0_32170593_24336.cpp:13:9: error: 'f' was not declared in this scope
  return f[x]==x?x:f[x]=find(f[x]); 
         ^
0_0_32170593_24336.cpp: In function 'void add(int, int, int)':
0_0_32170593_24336.cpp:17:8: error: 'last' was not declared in this scope
  tot++,last[tot]=head[x],head[x]=tot,to[tot]=y,val[tot]=v; 
        ^
0_0_32170593_24336.cpp:17:18: error: 'head' was not declared in this scope
  tot++,last[tot]=head[x],head[x]=tot,to[tot]=y,val[tot]=v; 
                  ^
0_0_32170593_24336.cpp:17:38: error: 'to' was not declared in this scope
  tot++,last[tot]=head[x],head[x]=tot,to[tot]=y,val[tot]=v; 
                                      ^
0_0_32170593_24336.cpp:17:48: error: 'val' was not declared in this scope
  tot++,last[tot]=head[x],head[x]=tot,to[tot]=y,val[tot]=v; 
                                                ^
0_0_32170593_24336.cpp: In function 'void dfs(int)':
0_0_32170593_24336.cpp:21:24: error: 'fa' was not declared in this scope
  for(int i=1;i<=14;i++)fa[x][i]=fa[fa[x][i-1]][i-1];
                        ^
0_0_32170593_24336.cpp:22:12: error: 'head' was not declared in this scope
  for(int i=head[x];i;i=last[i])
            ^
0_0_32170593_24336.cpp:22:24: error: 'last' was not declared in this scope
  for(int i=head[x];i;i=last[i])
                        ^
0_0_32170593_24336.cpp:24:6: error: 'fa' was not declared in this scope
   if(fa[x][0]!=to[i])
      ^
0_0_32170593_24336.cpp:24:16: error: 'to' was not declared in this scope
   if(fa[x][0]!=to[i])
                ^
0_0_32170593_24336.cpp:27:4: error: 'dep' was not declared in this scope
    dep[to[i]]=dep[x]+1;
    ^
0_0_32170593_24336.cpp:28:4: error: 'dis' was not declared in this scope
    dis[to[i]]=dis[x]+val[i];
    ^
0_0_32170593_24336.cpp:28:22: error: 'val' was not declared in this scope
    dis[to[i]]=dis[x]+val[i];
                      ^
0_0_32170593_24336.cpp: In function 'int lca(int, int)':
0_0_32170593_24336.cpp:35:5: error: 'dep' was not declared in this scope
  if(dep[x]<dep[y])x^=y,y^=x,x^=y;
     ^
0_0_32170593_24336.cpp:36:8: error: 'dep' was not declared in this scope
  int t=dep[x]-dep[y];
        ^
0_0_32170593_24336.cpp:39:17: error: 'fa' was not declared in this scope
   if((1<<i)&t)x=fa[x][i];
                 ^
0_0_32170593_24336.cpp:43:7: error: 'fa' was not declared in this scope
    if(fa[x][i]!=fa[y][i])x=fa[x][i],y=fa[y][i]; 
       ^
0_0_32170593_24336.cpp:45:10: error: 'fa' was not declared in this scope
   return fa[x][0];
          ^
0_0_32170593_24336.cpp: In function 'int main()':
0_0_32170593_24336.cpp:53:10: error: 'head' was not declared in this scope
   memset(head,0,sizeof(head));
          ^
0_0_32170593_24336.cpp:54:10: error: 'vis' was not declared in this scope
   memset(vis,0,sizeof(vis));
          ^
0_0_32170593_24336.cpp:55:10: error: 'fa' was not declared in this scope
   memset(fa,0,sizeof(fa));
          ^
0_0_32170593_24336.cpp:56:24: error: 'f' was not declared in this scope
   for(int i=1;i<=n;++i)f[i]=i;
                        ^
0_0_32170593_24336.cpp:62:4: error: 'f' was not declared in this scope
    f[fx]=fy;
    ^
0_0_32170593_24336.cpp:72:3: error: 'dep' was not declared in this scope
   dep[0]=1,dis[0]=0;
   ^
0_0_32170593_24336.cpp:72:12: error: 'dis' was not declared in this scope
   dep[0]=1,dis[0]=0;
            ^


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-11-26 04:49:31, Gzip enabled