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 |
为什么会错啊?代码很简单...#include<iostream> #include<algorithm> #include<string.h> using namespace std; int main() { char a[101],b[101]; while(scanf("%s%s",a,b)) { int i=0; for(i=0;i<strlen(b);i++) { b[i]+=1; } sort(a,a+strlen(a)); sort(b,b+strlen(b)); i=0; if(strcmp(a,b)==0)printf("YES\n");else printf("NO\n"); } return 0; } Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator