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_20612078_17148.cpp:11:71: error: stray '#' in program
     using namespace std;typedef long long lld;typedef unsigned int ud;#define INF_MAX 0x3f3f3f3f#define eatline() char chch;while((chch=getchar())!='\n')continue;#define MemsetMax(a) memset(a,0x3f,sizeof a)#define MemsetZero(a) memset(a,0,sizeof a)#define MemsetMin(a) memset(a,-1,sizeof a)#define MemsetFalse(a) MemsetZero(a)#define PQ priority_queue#define Q queue#define maxn 100005#define maxm 1000005int c[maxn];int Rank[maxm]; int main(){    int n, m;    while (scanf("%d%d", &n, &m) != EOF)    {        for (int i = 1; i <= n; i++)            scanf("%d", &c[i]);        for (int i = 1; i <= m; i++)            scanf("%d", &Rank[i]);        sort(Rank + 1, Rank + 1 + m);        int ans = 0;        for (int i = 1; i <= m; i++)        {            for (int j = 1; j <= Rank[i]; j++)            {                if (c[j] > 0)                {                    c[j]--;                    ans++;                    break;                }            }        }        printf("%d\n", ans);    }    return 0;}
                                                                       ^
0_0_20612078_17148.cpp:11:97: error: stray '#' in program
     using namespace std;typedef long long lld;typedef unsigned int ud;#define INF_MAX 0x3f3f3f3f#define eatline() char chch;while((chch=getchar())!='\n')continue;#define MemsetMax(a) memset(a,0x3f,sizeof a)#define MemsetZero(a) memset(a,0,sizeof a)#define MemsetMin(a) memset(a,-1,sizeof a)#define MemsetFalse(a) MemsetZero(a)#define PQ priority_queue#define Q queue#define maxn 100005#define maxm 1000005int c[maxn];int Rank[maxm]; int main(){    int n, m;    while (scanf("%d%d", &n, &m) != EOF)    {        for (int i = 1; i <= n; i++)            scanf("%d", &c[i]);        for (int i = 1; i <= m; i++)            scanf("%d", &Rank[i]);        sort(Rank + 1, Rank + 1 + m);        int ans = 0;        for (int i = 1; i <= m; i++)        {            for (int j = 1; j <= Rank[i]; j++)            {                if (c[j] > 0)                {                    c[j]--;                    ans++;                    break;                }            }        }        printf("%d\n", ans);    }    return 0;}
                                                                                                 ^
0_0_20612078_17148.cpp:11:163: error: stray '#' in program
     using namespace std;typedef long long lld;typedef unsigned int ud;#define INF_MAX 0x3f3f3f3f#define eatline() char chch;while((chch=getchar())!='\n')continue;#define MemsetMax(a) memset(a,0x3f,sizeof a)#define MemsetZero(a) memset(a,0,sizeof a)#define MemsetMin(a) memset(a,-1,sizeof a)#define MemsetFalse(a) MemsetZero(a)#define PQ priority_queue#define Q queue#define maxn 100005#define maxm 1000005int c[maxn];int Rank[maxm]; int main(){    int n, m;    while (scanf("%d%d", &n, &m) != EOF)    {        for (int i = 1; i <= n; i++)            scanf("%d", &c[i]);        for (int i = 1; i <= m; i++)            scanf("%d", &Rank[i]);        sort(Rank + 1, Rank + 1 + m);        int ans = 0;        for (int i = 1; i <= m; i++)        {            for (int j = 1; j <= Rank[i]; j++)            {                if (c[j] > 0)                {                    c[j]--;                    ans++;                    break;                }            }        }        printf("%d\n", ans);    }    return 0;}
                                                                                                                                                                   ^
0_0_20612078_17148.cpp:11:207: error: stray '#' in program
     using namespace std;typedef long long lld;typedef unsigned int ud;#define INF_MAX 0x3f3f3f3f#define eatline() char chch;while((chch=getchar())!='\n')continue;#define MemsetMax(a) memset(a,0x3f,sizeof a)#define MemsetZero(a) memset(a,0,sizeof a)#define MemsetMin(a) memset(a,-1,sizeof a)#define MemsetFalse(a) MemsetZero(a)#define PQ priority_queue#define Q queue#define maxn 100005#define maxm 1000005int c[maxn];int Rank[maxm]; int main(){    int n, m;    while (scanf("%d%d", &n, &m) != EOF)    {        for (int i = 1; i <= n; i++)            scanf("%d", &c[i]);        for (int i = 1; i <= m; i++)            scanf("%d", &Rank[i]);        sort(Rank + 1, Rank + 1 + m);        int ans = 0;        for (int i = 1; i <= m; i++)        {            for (int j = 1; j <= Rank[i]; j++)            {                if (c[j] > 0)                {                    c[j]--;                    ans++;                    break;                }            }        }        printf("%d\n", ans);    }    return 0;}
                                                                                                                                                                                                               ^
0_0_20612078_17148.cpp:11:249: error: stray '#' in program
     using namespace std;typedef long long lld;typedef unsigned int ud;#define INF_MAX 0x3f3f3f3f#define eatline() char chch;while((chch=getchar())!='\n')continue;#define MemsetMax(a) memset(a,0x3f,sizeof a)#define MemsetZero(a) memset(a,0,sizeof a)#define MemsetMin(a) memset(a,-1,sizeof a)#define MemsetFalse(a) MemsetZero(a)#define PQ priority_queue#define Q queue#define maxn 100005#define maxm 1000005int c[maxn];int Rank[maxm]; int main(){    int n, m;    while (scanf("%d%d", &n, &m) != EOF)    {        for (int i = 1; i <= n; i++)            scanf("%d", &c[i]);        for (int i = 1; i <= m; i++)            scanf("%d", &Rank[i]);        sort(Rank + 1, Rank + 1 + m);        int ans = 0;        for (int i = 1; i <= m; i++)        {            for (int j = 1; j <= Rank[i]; j++)            {                if (c[j] > 0)                {                    c[j]--;                    ans++;                    break;                }            }        }        printf("%d\n", ans);    }    return 0;}
                                                                                                                                                                                                                                                         ^
0_0_20612078_17148.cpp:11:291: error: stray '#' in program
     using namespace std;typedef long long lld;typedef unsigned int ud;#define INF_MAX 0x3f3f3f3f#define eatline() char chch;while((chch=getchar())!='\n')continue;#define MemsetMax(a) memset(a,0x3f,sizeof a)#define MemsetZero(a) memset(a,0,sizeof a)#define MemsetMin(a) memset(a,-1,sizeof a)#define MemsetFalse(a) MemsetZero(a)#define PQ priority_queue#define Q queue#define maxn 100005#define maxm 1000005int c[maxn];int Rank[maxm]; int main(){    int n, m;    while (scanf("%d%d", &n, &m) != EOF)    {        for (int i = 1; i <= n; i++)            scanf("%d", &c[i]);        for (int i = 1; i <= m; i++)            scanf("%d", &Rank[i]);        sort(Rank + 1, Rank + 1 + m);        int ans = 0;        for (int i = 1; i <= m; i++)        {            for (int j = 1; j <= Rank[i]; j++)            {                if (c[j] > 0)                {                    c[j]--;                    ans++;                    break;                }            }        }        printf("%d\n", ans);    }    return 0;}
                                                                                                                                                                                                                                                                                                   ^
0_0_20612078_17148.cpp:11:327: error: stray '#' in program
     using namespace std;typedef long long lld;typedef unsigned int ud;#define INF_MAX 0x3f3f3f3f#define eatline() char chch;while((chch=getchar())!='\n')continue;#define MemsetMax(a) memset(a,0x3f,sizeof a)#define MemsetZero(a) memset(a,0,sizeof a)#define MemsetMin(a) memset(a,-1,sizeof a)#define MemsetFalse(a) MemsetZero(a)#define PQ priority_queue#define Q queue#define maxn 100005#define maxm 1000005int c[maxn];int Rank[maxm]; int main(){    int n, m;    while (scanf("%d%d", &n, &m) != EOF)    {        for (int i = 1; i <= n; i++)            scanf("%d", &c[i]);        for (int i = 1; i <= m; i++)            scanf("%d", &Rank[i]);        sort(Rank + 1, Rank + 1 + m);        int ans = 0;        for (int i = 1; i <= m; i++)        {            for (int j = 1; j <= Rank[i]; j++)            {                if (c[j] > 0)                {                    c[j]--;                    ans++;                    break;                }            }        }        printf("%d\n", ans);    }    return 0;}
                                                                                                                                                                                                                                                                                                                                       ^
0_0_20612078_17148.cpp:11:352: error: stray '#' in program
     using namespace std;typedef long long lld;typedef unsigned int ud;#define INF_MAX 0x3f3f3f3f#define eatline() char chch;while((chch=getchar())!='\n')continue;#define MemsetMax(a) memset(a,0x3f,sizeof a)#define MemsetZero(a) memset(a,0,sizeof a)#define MemsetMin(a) memset(a,-1,sizeof a)#define MemsetFalse(a) MemsetZero(a)#define PQ priority_queue#define Q queue#define maxn 100005#define maxm 1000005int c[maxn];int Rank[maxm]; int main(){    int n, m;    while (scanf("%d%d", &n, &m) != EOF)    {        for (int i = 1; i <= n; i++)            scanf("%d", &c[i]);        for (int i = 1; i <= m; i++)            scanf("%d", &Rank[i]);        sort(Rank + 1, Rank + 1 + m);        int ans = 0;        for (int i = 1; i <= m; i++)        {            for (int j = 1; j <= Rank[i]; j++)            {                if (c[j] > 0)                {                    c[j]--;                    ans++;                    break;                }            }        }        printf("%d\n", ans);    }    return 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-25 13:17:01, Gzip enabled