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_20613867_15779.cpp:9:5: error: expected unqualified-id before '=' token
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=0;            }            else len++;        }        ans^=sg[len];        printf("Case %d: %s\n",++k,ans?"Alice":"Bob");    }    return 0;}
     ^
0_0_20613867_15779.cpp:9:32: error: expected constructor, destructor, or type conversion before '(' token
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=0;            }            else len++;        }        ans^=sg[len];        printf("Case %d: %s\n",++k,ans?"Alice":"Bob");    }    return 0;}
                                ^
0_0_20613867_15779.cpp:9:56: error: expected unqualified-id before 'for'
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=0;            }            else len++;        }        ans^=sg[len];        printf("Case %d: %s\n",++k,ans?"Alice":"Bob");    }    return 0;}
                                                        ^
0_0_20613867_15779.cpp:9:64: error: 'i' does not name a type
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=0;            }            else len++;        }        ans^=sg[len];        printf("Case %d: %s\n",++k,ans?"Alice":"Bob");    }    return 0;}
                                                                ^
0_0_20613867_15779.cpp:9:73: error: 'i' does not name a type
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=0;            }            else len++;        }        ans^=sg[len];        printf("Case %d: %s\n",++k,ans?"Alice":"Bob");    }    return 0;}
                                                                         ^
0_0_20613867_15779.cpp:9:120: error: expected unqualified-id before 'for'
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=0;            }            else len++;        }        ans^=sg[len];        printf("Case %d: %s\n",++k,ans?"Alice":"Bob");    }    return 0;}
                                                                                                                        ^
0_0_20613867_15779.cpp:9:128: error: 'i' does not name a type
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=0;            }            else len++;        }        ans^=sg[len];        printf("Case %d: %s\n",++k,ans?"Alice":"Bob");    }    return 0;}
                                                                                                                                ^
0_0_20613867_15779.cpp:9:137: error: 'i' does not name a type
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=0;            }            else len++;        }        ans^=sg[len];        printf("Case %d: %s\n",++k,ans?"Alice":"Bob");    }    return 0;}
                                                                                                                                         ^
0_0_20613867_15779.cpp:9:182: error: 'i' does not name a type
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=0;            }            else len++;        }        ans^=sg[len];        printf("Case %d: %s\n",++k,ans?"Alice":"Bob");    }    return 0;}
                                                                                                                                                                                      ^
0_0_20613867_15779.cpp:9:190: error: expected unqualified-id before 'while'
     =0) return sg[x];    memset(vis,0,sizeof(vis));    for(i=0;i<=x-i-1;i++)        vis[getsg(i)^getsg(x-i-1)^1]=1;    for(i=0;i<=x-i-2;i++)        vis[getsg(i)^getsg(x-i-2)]=1;    i=0;    while(vis[i]) i++;    return sg[x]=i;}int main(){    int t,m,n,s,c,ans,i,k=0,len;    memset(sg,-1,sizeof(sg));    sg[0]=0;    for(i=1;i<=4747;i++) sg[i]=getsg(i);    scanf("%d",&t);    while(t--){        scanf("%d %d",&n,&m);        memset(an,0,sizeof(an));        for(i=0;i<m;i++){            scanf("%d %d",&s,&c);            an[s-1][c-1]=1;        }        ans=0;len=0;        for(i=0;i<n;i++){            if(an[0][i]||an[1][i]){                ans^=sg[len];                ans^=an[0][i];                ans^=an[1][i];                len=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 03:24:02, Gzip enabled