杭电acm1161题为什么是Presentation Error啊???请教大牛,谢谢啊

Eddy'smistakesTimeLimit:2000/1000MS(Java/Others)MemoryLimit:65536/32768K(Java/Others)... Eddy's mistakes
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 3718 Accepted Submission(s): 2101

Problem Description
Eddy usually writes articles ,but he likes mixing the English letter uses, for example "computer science" is written frequently "coMpUtEr scIeNce" by him, this mistakes lets Eddy's English teacher be extremely discontentment.Now please you to write a procedure to be able in the Bob article English letter to turn completely the small letter.

Input
The input contains several test cases.each line consists a test case,Expressed Eddy writes in an article , by letter, blank space,numeral as well as each kind of punctuation
composition, the writing length does not surpass 1000 characters.

Output
For each test case, you should output an only line, after namely the result of transforms the lowercase letter.

Sample Input
weLcOmE tO HDOj Acm 2005!

Sample Output
welcome to hdoj acm 2005!

Author
eddy

Recommend
JGShining
代码是
#include<stdio.h>
main()
{
int i,n;
char ch[2000];
while(scanf("%d",&n)!=EOF){
gets(ch);
for(i=0;ch[i];i++)
if(ch[i]>='A'&&ch[i]<='Z')
ch[i]=ch[i]+32;
for(i=0;ch[i];i++)
printf("%c",ch[i]);

printf("\n");
}
}
展开
 我来答
porker2008
2011-08-24 · TA获得超过1.4万个赞
知道大有可为答主
回答量:7066
采纳率:62%
帮助的人:1.1亿
展开全部
分给我吧
#include<stdio.h>
main()
{
int i,n;
char ch[2000];
while(gets(ch)){
for(i=0;ch[i];i++)
if(ch[i]>='A'&&ch[i]<='Z')
ch[i]=ch[i]+32;
for(i=0;ch[i];i++)
printf("%c",ch[i]);
printf("\n");
}
}
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式