标签:des style blog http io ar color os sp
zoj ozojo ozoojoo oozoojoooo zooj ozojo oooozojo zojoooo
Accepted Accepted Accepted Accepted Accepted Accepted Wrong Answer Wrong Answer
//a*b==c即Aceeptd,a表示z之前o的个数, //b表示zj之间o的个数,c表示j之后o个数 #include<stdio.h> #include<string.h> char s[1002]; int main() { int i,len,a,b,c,d,e; while(scanf("%s",s)!=EOF) { len=strlen(s); for(i=0;i<len;i++) { if(s[i]=='z') a=i; if(s[i]=='j') b=i-a-1; } c=len-a-b-2; if(a==0) { if(b>0&&c==0) printf("Accepted\n"); else printf("Wrong Answer\n"); } else { if(a*b==c&&b>0) printf("Accepted\n"); else printf("Wrong Answer\n"); } } return 0; }
标签:des style blog http io ar color os sp
原文地址:http://blog.csdn.net/hdd871532887/article/details/41832923