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_20999539_4138.cpp: In function 'void init()':
0_0_20999539_4138.cpp:3:12: error: 'd' was not declared in this scope
     memset(d,0,sizeof(d));
            ^
0_0_20999539_4138.cpp:3:25: error: 'memset' was not declared in this scope
     memset(d,0,sizeof(d));
                         ^
0_0_20999539_4138.cpp:4:12: error: 'vis1' was not declared in this scope
     memset(vis1,0,sizeof(vis1));
            ^
0_0_20999539_4138.cpp:5:13: error: 'vis2' was not declared in this scope
      memset(vis2,0,sizeof(vis2));
             ^
0_0_20999539_4138.cpp:6:20: error: 'N' was not declared in this scope
      for(int i=0;i<N;i++) g[i].clear();
                    ^
0_0_20999539_4138.cpp:6:27: error: 'g' was not declared in this scope
      for(int i=0;i<N;i++) g[i].clear();
                           ^
0_0_20999539_4138.cpp: In function 'void dfs(int, int)':
0_0_20999539_4138.cpp:10:5: error: 'd' was not declared in this scope
     d[u]=d[fa]+1;
     ^
0_0_20999539_4138.cpp:11:8: error: 'vis1' was not declared in this scope
     if(vis1[d[u]])
        ^
0_0_20999539_4138.cpp:14:10: error: 'f' was not declared in this scope
         {f=1;
          ^
0_0_20999539_4138.cpp:19:13: error: 'g' was not declared in this scope
     int len=g[u].size();
             ^
0_0_20999539_4138.cpp:20:15: error: 'vis2' was not declared in this scope
     if(len>1) vis2[u]=1;
               ^
0_0_20999539_4138.cpp:27:24: error: 'vis2' was not declared in this scope
              if(u!=fa&&vis2[fa]) f=1;
                        ^
0_0_20999539_4138.cpp:27:34: error: 'f' was not declared in this scope
              if(u!=fa&&vis2[fa]) f=1;
                                  ^
0_0_20999539_4138.cpp: In function 'int main()':
0_0_20999539_4138.cpp:35:25: error: 'scanf' was not declared in this scope
     while(~scanf("%d",&n))
                         ^
0_0_20999539_4138.cpp:41:13: error: 'g' was not declared in this scope
             g[u].push_back(v);
             ^
0_0_20999539_4138.cpp:44:9: error: 'f' was not declared in this scope
         f=0;
         ^
0_0_20999539_4138.cpp:46:24: error: 'puts' was not declared in this scope
         if(f) puts("NO");
                        ^
0_0_20999539_4138.cpp:47:24: error: 'puts' was not declared in this scope
         else puts("YES");
                        ^


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-17 07:14:18, Gzip enabled