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_21957488_14627.cpp: In function 'int main()':
0_0_21957488_14627.cpp:12:3: error: 'T' was not declared in this scope
   T=get();
   ^
0_0_21957488_14627.cpp:15:19: error: 'n' was not declared in this scope
     scanf("%d%d",&n,&m);
                   ^
0_0_21957488_14627.cpp:15:22: error: 'm' was not declared in this scope
     scanf("%d%d",&n,&m);
                      ^
0_0_21957488_14627.cpp:16:38: error: 'x' was not declared in this scope
     for(int i=2;i<=n;i++)scanf("%d",&x),fa[i]=x;
                                      ^
0_0_21957488_14627.cpp:16:41: error: 'fa' was not declared in this scope
     for(int i=2;i<=n;i++)scanf("%d",&x),fa[i]=x;
                                         ^
0_0_21957488_14627.cpp:19:7: error: 'flag' was not declared in this scope
    if(flag[x]||flag[fa[x]])continue;
       ^
0_0_21957488_14627.cpp:19:12: error: 'x' was not declared in this scope
    if(flag[x]||flag[fa[x]])continue;
            ^
0_0_21957488_14627.cpp:19:21: error: 'fa' was not declared in this scope
    if(flag[x]||flag[fa[x]])continue;
                     ^
0_0_21957488_14627.cpp:20:4: error: 'flag' was not declared in this scope
    flag[x]=1;flag[fa[x]]=1;ans++;
    ^
0_0_21957488_14627.cpp:20:9: error: 'x' was not declared in this scope
    flag[x]=1;flag[fa[x]]=1;ans++;
         ^
0_0_21957488_14627.cpp:20:19: error: 'fa' was not declared in this scope
    flag[x]=1;flag[fa[x]]=1;ans++;
                   ^
0_0_21957488_14627.cpp:20:28: error: 'ans' was not declared in this scope
    flag[x]=1;flag[fa[x]]=1;ans++;
                            ^
0_0_21957488_14627.cpp:22:5: error: 'ans' was not declared in this scope
  if(ans>=m*2)printf("%d\n",(m+1)/2);
     ^


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-29 20:53:17, Gzip enabled