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_20935052_19380.cpp:13:21: error: stray '#' in program
  for(int i=1;i<=n;i++){
                     ^
0_0_20935052_19380.cpp:13:26: error: stray '#' in program
  for(int i=1;i<=n;i++){
                          ^
0_0_20935052_19380.cpp:25:20: error: stray '#' in program
   rank[x]=(rank[x]+rank[tmp]+1)%2;
                    ^
0_0_20935052_19380.cpp:25:34: error: stray '#' in program
   rank[x]=(rank[x]+rank[tmp]+1)%2;
                                  ^
0_0_20935052_19380.cpp:39:21: error: stray '#' in program
   rank[fa]=(rank[x]+rank[y])%2;
                     ^
0_0_20935052_19380.cpp:55:17: error: stray '#' in program
     if((rank[a]+rank[b])%2==0) 
                 ^
0_0_20935052_19380.cpp: In function 'void Init_set(int)':
0_0_20935052_19380.cpp:13:24: error: expected ')' before ';' token
  for(int i=1;i<=n;i++){
                        ^
0_0_20935052_19380.cpp:13:27: error: lvalue required as unary '&' operand
  for(int i=1;i<=n;i++){
                           ^
0_0_20935052_19380.cpp:13:30: error: expected primary-expression before ')' token
  for(int i=1;i<=n;i++){
                              ^
0_0_20935052_19380.cpp: In function 'int find_set(int)':
0_0_20935052_19380.cpp:25:3: error: reference to 'rank' is ambiguous
   rank[x]=(rank[x]+rank[tmp]+1)%2;
   ^
0_0_20935052_19380.cpp:9:5: note: candidates are: int rank [100005]
 int rank[N];
     ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/move.h:57:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:59,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:64,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_20935052_19380.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/type_traits:1340:12: note:                 template<class> struct std::rank
     struct rank
            ^
0_0_20935052_19380.cpp:25:12: error: reference to 'rank' is ambiguous
   rank[x]=(rank[x]+rank[tmp]+1)%2;
            ^
0_0_20935052_19380.cpp:9:5: note: candidates are: int rank [100005]
 int rank[N];
     ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/move.h:57:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:59,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:64,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_20935052_19380.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/type_traits:1340:12: note:                 template<class> struct std::rank
     struct rank
            ^
0_0_20935052_19380.cpp:25:23: error: expected ')' before ';' token
   rank[x]=(rank[x]+rank[tmp]+1)%2;
                       ^
0_0_20935052_19380.cpp:25:24: error: reference to 'rank' is ambiguous
   rank[x]=(rank[x]+rank[tmp]+1)%2;
                        ^
0_0_20935052_19380.cpp:9:5: note: candidates are: int rank [100005]
 int rank[N];
     ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/move.h:57:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:59,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:64,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_20935052_19380.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/type_traits:1340:12: note:                 template<class> struct std::rank
     struct rank
            ^
0_0_20935052_19380.cpp:25:39: error: expected ';' before ')' token
   rank[x]=(rank[x]+rank[tmp]+1)%2;
                                       ^
0_0_20935052_19380.cpp: In function 'void Union_set(int, int)':
0_0_20935052_19380.cpp:39:3: error: reference to 'rank' is ambiguous
   rank[fa]=(rank[x]+rank[y])%2;
   ^
0_0_20935052_19380.cpp:9:5: note: candidates are: int rank [100005]
 int rank[N];
     ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/move.h:57:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:59,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:64,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_20935052_19380.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/type_traits:1340:12: note:                 template<class> struct std::rank
     struct rank
            ^
0_0_20935052_19380.cpp:39:13: error: reference to 'rank' is ambiguous
   rank[fa]=(rank[x]+rank[y])%2;
             ^
0_0_20935052_19380.cpp:9:5: note: candidates are: int rank [100005]
 int rank[N];
     ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/move.h:57:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:59,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:64,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_20935052_19380.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/type_traits:1340:12: note:                 template<class> struct std::rank
     struct rank
            ^
0_0_20935052_19380.cpp:39:24: error: expected ')' before ';' token
   rank[fa]=(rank[x]+rank[y])%2;
                        ^
0_0_20935052_19380.cpp:39:25: error: reference to 'rank' is ambiguous
   rank[fa]=(rank[x]+rank[y])%2;
                         ^
0_0_20935052_19380.cpp:9:5: note: candidates are: int rank [100005]
 int rank[N];
     ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/move.h:57:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:59,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:64,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_20935052_19380.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/type_traits:1340:12: note:                 template<class> struct std::rank
     struct rank
            ^
0_0_20935052_19380.cpp: In function 'int main()':
0_0_20935052_19380.cpp:55:9: error: reference to 'rank' is ambiguous
     if((rank[a]+rank[b])%2==0) 
         ^
0_0_20935052_19380.cpp:9:5: note: candidates are: int rank [100005]
 int rank[N];
     ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/move.h:57:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_pair.h:59,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:64,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ostream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/iostream:39,
                 from 0_0_20935052_19380.cpp:1:
GCC4.9.2/x86_64-w64-mingw32/include/c++/type_traits:1340:12: note:                 template<class> struct std::rank
     struct rank
            ^
0_0_20935052_19380.cpp:55:20: error: expected ')' before ';' token
     if((rank[a]+rank[b])%2==0) 
                    ^
0_0_20935052_19380.cpp:55:20: error: expected ')' before ';' token
0_0_20935052_19380.cpp:55:21: error: reference to 'rank' is ambiguous
     if((rank[a]+rank[b])%2==0) 


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2025 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2025-02-28 00:00:47, Gzip enabled