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_20612766_11391.cpp:5:26: error: stray '#' in program
     using namespace std; #define N 32#define cls(a) memset(a, 0, sizeof(a))#define cls1(a,i,j) memset(a+i, 1, (j-i+1)*sizeof(bool))#define cls0(a, i)    memset(a, 0, i*sizeof(bool)) struct computer{    bool able[1005];    int pcent;}cpt[N]; bool isSver[N];int Sver[N];int Clnt[N];int rate[N][N]; int main(){    int d, n, t, k, s, i, j, l, st, ed, m, c;    scanf("%d", &d);    while(d--)    {        cls(isSver);        cls(Clnt);        cls(Sver);        cls(cpt);        cls(rate);         scanf("%d%d", &n, &t);        scanf("%d%d", &s, &k);        for(i=0; i<s; i++)        {            scanf("%d", Sver+i);            isSver[Sver[i]] = 1;            cpt[Sver[i]].pcent = k;        }         for(c=0, i=1; i<=n; i++)        {            if(!isSver[i]) Clnt[c++] = i;        }         for(i=1; i<=n; i++)        {            for(j=1; j<=n; j++)            {                scanf("%d", rate[i]+j);            }        }         for(i=1; i<=n; i++)        {            scanf("%d", &m);            for(j=0; j<m; j++)            {                scanf("%d%d", &st, &ed);                if(st > t) continue;                if(ed > t) ed = t;                for(l=st; l<ed; l++) cpt[i].able[l] = 1;            }        }         scanf("%d", &m);        for(i=0; i<m; i++)        {            scanf("%d%d", &ed, &st);            cls0(cpt[st].able, ed);        }         for(i=0; i<=t; i++)        {            for(j=0; j<c; j++)            {                if(cpt[Clnt[j]].able[i])                {                    for(l=0; l<s; l++)                    {                        if(cpt[Sver[l]].able[i])                        {                            cpt[Clnt[j]].pcent += rate[Clnt[j]][Sver[l]];                        }                    }                }            }            for(j=0; j<c; j++)                if(cpt[Clnt[j]].pcent >= k)                {                    isSver[Clnt[j]] = 1;                    Sver[s++] = Clnt[j];                    for(c--, l=j; l<c; l++)                        Clnt[l] = Clnt[l+1];                }        }         for(i=1; i<=n; i++)        {            printf("%d%%\n", cpt[i].pcent>=k ? 100 : (cpt[i].pcent*100/k));        }    }     return 0;}
                          ^
0_0_20612766_11391.cpp:5:38: error: stray '#' in program
     using namespace std; #define N 32#define cls(a) memset(a, 0, sizeof(a))#define cls1(a,i,j) memset(a+i, 1, (j-i+1)*sizeof(bool))#define cls0(a, i)    memset(a, 0, i*sizeof(bool)) struct computer{    bool able[1005];    int pcent;}cpt[N]; bool isSver[N];int Sver[N];int Clnt[N];int rate[N][N]; int main(){    int d, n, t, k, s, i, j, l, st, ed, m, c;    scanf("%d", &d);    while(d--)    {        cls(isSver);        cls(Clnt);        cls(Sver);        cls(cpt);        cls(rate);         scanf("%d%d", &n, &t);        scanf("%d%d", &s, &k);        for(i=0; i<s; i++)        {            scanf("%d", Sver+i);            isSver[Sver[i]] = 1;            cpt[Sver[i]].pcent = k;        }         for(c=0, i=1; i<=n; i++)        {            if(!isSver[i]) Clnt[c++] = i;        }         for(i=1; i<=n; i++)        {            for(j=1; j<=n; j++)            {                scanf("%d", rate[i]+j);            }        }         for(i=1; i<=n; i++)        {            scanf("%d", &m);            for(j=0; j<m; j++)            {                scanf("%d%d", &st, &ed);                if(st > t) continue;                if(ed > t) ed = t;                for(l=st; l<ed; l++) cpt[i].able[l] = 1;            }        }         scanf("%d", &m);        for(i=0; i<m; i++)        {            scanf("%d%d", &ed, &st);            cls0(cpt[st].able, ed);        }         for(i=0; i<=t; i++)        {            for(j=0; j<c; j++)            {                if(cpt[Clnt[j]].able[i])                {                    for(l=0; l<s; l++)                    {                        if(cpt[Sver[l]].able[i])                        {                            cpt[Clnt[j]].pcent += rate[Clnt[j]][Sver[l]];                        }                    }                }            }            for(j=0; j<c; j++)                if(cpt[Clnt[j]].pcent >= k)                {                    isSver[Clnt[j]] = 1;                    Sver[s++] = Clnt[j];                    for(c--, l=j; l<c; l++)                        Clnt[l] = Clnt[l+1];                }        }         for(i=1; i<=n; i++)        {            printf("%d%%\n", cpt[i].pcent>=k ? 100 : (cpt[i].pcent*100/k));        }    }     return 0;}
                                      ^
0_0_20612766_11391.cpp:5:76: error: stray '#' in program
     using namespace std; #define N 32#define cls(a) memset(a, 0, sizeof(a))#define cls1(a,i,j) memset(a+i, 1, (j-i+1)*sizeof(bool))#define cls0(a, i)    memset(a, 0, i*sizeof(bool)) struct computer{    bool able[1005];    int pcent;}cpt[N]; bool isSver[N];int Sver[N];int Clnt[N];int rate[N][N]; int main(){    int d, n, t, k, s, i, j, l, st, ed, m, c;    scanf("%d", &d);    while(d--)    {        cls(isSver);        cls(Clnt);        cls(Sver);        cls(cpt);        cls(rate);         scanf("%d%d", &n, &t);        scanf("%d%d", &s, &k);        for(i=0; i<s; i++)        {            scanf("%d", Sver+i);            isSver[Sver[i]] = 1;            cpt[Sver[i]].pcent = k;        }         for(c=0, i=1; i<=n; i++)        {            if(!isSver[i]) Clnt[c++] = i;        }         for(i=1; i<=n; i++)        {            for(j=1; j<=n; j++)            {                scanf("%d", rate[i]+j);            }        }         for(i=1; i<=n; i++)        {            scanf("%d", &m);            for(j=0; j<m; j++)            {                scanf("%d%d", &st, &ed);                if(st > t) continue;                if(ed > t) ed = t;                for(l=st; l<ed; l++) cpt[i].able[l] = 1;            }        }         scanf("%d", &m);        for(i=0; i<m; i++)        {            scanf("%d%d", &ed, &st);            cls0(cpt[st].able, ed);        }         for(i=0; i<=t; i++)        {            for(j=0; j<c; j++)            {                if(cpt[Clnt[j]].able[i])                {                    for(l=0; l<s; l++)                    {                        if(cpt[Sver[l]].able[i])                        {                            cpt[Clnt[j]].pcent += rate[Clnt[j]][Sver[l]];                        }                    }                }            }            for(j=0; j<c; j++)                if(cpt[Clnt[j]].pcent >= k)                {                    isSver[Clnt[j]] = 1;                    Sver[s++] = Clnt[j];                    for(c--, l=j; l<c; l++)                        Clnt[l] = Clnt[l+1];                }        }         for(i=1; i<=n; i++)        {            printf("%d%%\n", cpt[i].pcent>=k ? 100 : (cpt[i].pcent*100/k));        }    }     return 0;}
                                                                            ^
0_0_20612766_11391.cpp:5:132: error: stray '#' in program
     using namespace std; #define N 32#define cls(a) memset(a, 0, sizeof(a))#define cls1(a,i,j) memset(a+i, 1, (j-i+1)*sizeof(bool))#define cls0(a, i)    memset(a, 0, i*sizeof(bool)) struct computer{    bool able[1005];    int pcent;}cpt[N]; bool isSver[N];int Sver[N];int Clnt[N];int rate[N][N]; int main(){    int d, n, t, k, s, i, j, l, st, ed, m, c;    scanf("%d", &d);    while(d--)    {        cls(isSver);        cls(Clnt);        cls(Sver);        cls(cpt);        cls(rate);         scanf("%d%d", &n, &t);        scanf("%d%d", &s, &k);        for(i=0; i<s; i++)        {            scanf("%d", Sver+i);            isSver[Sver[i]] = 1;            cpt[Sver[i]].pcent = k;        }         for(c=0, i=1; i<=n; i++)        {            if(!isSver[i]) Clnt[c++] = i;        }         for(i=1; i<=n; i++)        {            for(j=1; j<=n; j++)            {                scanf("%d", rate[i]+j);            }        }         for(i=1; i<=n; i++)        {            scanf("%d", &m);            for(j=0; j<m; j++)            {                scanf("%d%d", &st, &ed);                if(st > t) continue;                if(ed > t) ed = t;                for(l=st; l<ed; l++) cpt[i].able[l] = 1;            }        }         scanf("%d", &m);        for(i=0; i<m; i++)        {            scanf("%d%d", &ed, &st);            cls0(cpt[st].able, ed);        }         for(i=0; i<=t; i++)        {            for(j=0; j<c; j++)            {                if(cpt[Clnt[j]].able[i])                {                    for(l=0; l<s; l++)                    {                        if(cpt[Sver[l]].able[i])                        {                            cpt[Clnt[j]].pcent += rate[Clnt[j]][Sver[l]];                        }                    }                }            }            for(j=0; j<c; j++)                if(cpt[Clnt[j]].pcent >= k)                {                    isSver[Clnt[j]] = 1;                    Sver[s++] = Clnt[j];                    for(c--, l=j; l<c; l++)                        Clnt[l] = Clnt[l+1];                }        }         for(i=1; i<=n; i++)        {            printf("%d%%\n", cpt[i].pcent>=k ? 100 : (cpt[i].pcent*100/k));        }    }     return 0;}
                                                                                                                                    ^
0_0_20612766_11391.cpp:5:27: error: 'define' does not name a type
     using namespace std; #define N 32#define cls(a) memset(a, 0, sizeof(a))#define cls1(a,i,j) memset(a+i, 1, (j-i+1)*sizeof(bool))#define cls0(a, i)    memset(a, 0, i*sizeof(bool)) struct computer{    bool able[1005];    int pcent;}cpt[N]; bool isSver[N];int Sver[N];int Clnt[N];int rate[N][N]; int main(){    int d, n, t, k, s, i, j, l, st, ed, m, c;    scanf("%d", &d);    while(d--)    {        cls(isSver);        cls(Clnt);        cls(Sver);        cls(cpt);        cls(rate);         scanf("%d%d", &n, &t);        scanf("%d%d", &s, &k);        for(i=0; i<s; i++)        {            scanf("%d", Sver+i);            isSver[Sver[i]] = 1;            cpt[Sver[i]].pcent = k;        }         for(c=0, i=1; i<=n; i++)        {            if(!isSver[i]) Clnt[c++] = i;        }         for(i=1; i<=n; i++)     


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:09:21, Gzip enabled