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_24089866_13034.cpp:18:9: error: 'MAX_N' was not declared in this scope
  int fa[MAX_N];
         ^
0_0_24089866_13034.cpp: In member function 'void UF::init()':
0_0_24089866_13034.cpp:19:36: error: 'MAX_N' was not declared in this scope
  void init() { for (int i = 1; i < MAX_N; i++) fa[i] = i; }
                                    ^
0_0_24089866_13034.cpp:19:48: error: 'fa' was not declared in this scope
  void init() { for (int i = 1; i < MAX_N; i++) fa[i] = i; }
                                                ^
0_0_24089866_13034.cpp: In member function 'int UF::find(int)':
0_0_24089866_13034.cpp:20:27: error: 'fa' was not declared in this scope
  int find(int a) { return fa[a] == a ? a : fa[a] = find(fa[a]); }
                           ^
0_0_24089866_13034.cpp: In member function 'void UF::mix(int, int)':
0_0_24089866_13034.cpp:21:27: error: 'fa' was not declared in this scope
  void mix(int a, int b) { fa[find(a)] = find(b); }
                           ^


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-18 11:21:43, Gzip enabled