Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
为啥总是wa呢?#include<stdio.h> #include<string.h> #define NULL 0 main() {char a[10000][11]; int i=0,j,k; while(gets(a[i])!=NULL) i++;k=i; for(j=0;a[0][j]!='\0';j++) for(i=1;i<k;i++) {a[0][j]=a[i][j]-'0'+a[0][j]; while(a[0][j]>'9')a[0][j]-=10;} puts(a[0]); } Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator