什么是toupper

核心提示toupper,是一种计算机用语,用来将字符c转换为大写英文字母。中文名toupper原型extern int toupper(int c);用法#include功能将字符c转换为大写英文字母toupperC语言原型extern int t

最佳答案:

toupper,是一种计算机用语,用来将字符c转换为大写英文字母。

详情介绍

toupper,是一种计算机用语,用来将字符c转换为大写英文字母。

中文名
toupper
原型
extern int toupper(int c);
用法
#include
功能
将字符c转换为大写英文字母

toupperC语言原型

extern int toupper(int c);

toupper用法

#include <ctype.h>

toupper功能

将字符c转换为大写英文字母

toupper说明

如果c为小写英文字母,则返回对应的大写字母;否则返回原来的值。

toupper举例

// toupper.c#include <stdio.h>#include <string.h>#include <ctype.h>int main(){    char *s="Hello, World!";    int i;    //clrscr(); // clear screen    printf("%sn",s);    for(i=0;i<strlen(s);i++)    {        putchar(toupper(s));    }    getchar();    return 0;}

相关函数:tolower

 
友情链接
鄂ICP备19019357号-22