Problem 1059 老师的苦恼

Bob写文章时喜欢将英文字母的大小写混用,例如Computer Science经常被他写成coMpUtEr scIeNce,这让他的英文老师十分苦恼,现在请你帮Bob的英文老师写一个程序能够将Bob的文章中的英文字母全部变成小写的。

Input

输入数据由多组数据组成。每组数据只有一行,表示Bob写的文章中的一句话,由字母、空格、数字以及各种标点组成,文字长度不超过50个字符。

Output

对于每组数据,输出仅一行,即转换成小写字母之后的结果。

Sample Input

weLcOmE tO FZuPC 2005!

Sample Output

welcome to fzupc 2005!


#include<cctype>
#include<cstdio>
using namespace std;
char s[50+5];
int main()
{
while (gets(s))
{
for (int i = 0; s[i]; i++) putchar(tolower(s[i]));
putchar('\n');
}
return 0;
}

猜你喜欢

转载自blog.csdn.net/hujinhong145/article/details/79905632
今日推荐