|
|
back to boardWhy I got WA?? Please HELP!!! (in C) Posted by 55555 30 Jul 2003 14:50 #include <stdio.h> void main() { long n,m,p,i,j,a[27]={0}; char c; scanf("%ld %ld %ld\n",&n,&m,&p); for(i=1;i<=n;i++) { for(j=1;j<=m;j++) { scanf("%c",&c); a[c-64]++; } } for(i=1;i<=p;i++) { zy: scanf("%c",&c); if(c=='\n') goto zy; else a[c-64]--; while(c>='A'&&c<='Z') { scanf("%c",&c); a[c-64]--; } } for(i=1;i<=26;i++) for(j=1;j<=a[i];j++) printf("%c",i+64); } |
|
|