C语言大小写转化

[复制链接]
查看11 | 回复1 | 2015-12-29 22:16:33 | 显示全部楼层 |阅读模式
你这个程序完全错了strlwr(string)是把所有的大写转成小写strupr(string)是把所有的小写转成大写而且if((string>='A')&&(string='a')&&(string='A')&&(string='a')&&(string#includeintmain(void){ charch; scanf("%c",&ch); tolower(ch); printf("%c\n",ch); return0;}如果硬要那么写,就ch=(ch>='a'&&ch='A')&&(string='a')&&(string#includeint main(){ int i;char string[80]; gets(string); for(i=0;i='A')&&(string='a')&&(string#include#includeint main(){ int i;char string[80]; gets(string); for(i=0;i='A')&&(string='a')&&(string='a')&&(string='a')&&(string<='z')) strupr(string);}
回复

使用道具 举报

千问 | 2015-12-29 22:16:33 | 显示全部楼层
楼上两位说的都不对啊
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行