| ||||||||||
| 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 | |||||||||
Re:好奇怪!我觉得我的代码没错为什么总AC不了??In Reply To:好奇怪!我觉得我的代码没错为什么总AC不了?? Posted by:shuiye at 2007-08-24 10:23:52 > #include<stdio.h>
> #include<string.h>
> int main()
> { char s[200];
> int i,j;
> while(scanf("%s",s)!=EOF)
> {
> if(strcmp(s,"START")==0||strcmp(s,"END")==0)
> continue;
> if(strcmp(s,"ENDOFINPUT")==0)
> break;
> for(i=0;i<strlen(s);i++)
> {
> if(s[i]>='A'&&s[i]<='E')
> {
> s[i]=s[i]+21;
>
> }
> if(s[i]>'E'&&s[i]<='Z')
> {
> s[i]=s[i]-5;
>
> }
> }
> printf("%s\n",s);
>
>
> }
>
> return 0;
>
> }
>
Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator