strlen函数
来源:互联网 发布:红外线软件下载 编辑:程序博客网 时间:2024/05/23 21:16
函数原型:extern int strlen(char *str)
参数说明:str要被计算的字符串。
所在库名:#include <string.h>
函数功能:计算字符串str的长度,但是不包含“/0”。
返回说明:返回字符串str的长度,是一个整型值。
其它说明:暂时无。
实例:
#include <string.h>
#include <stdio.h>
int main()
...{
char *str="sky2098,I like writing!";
int inttemp;
inttemp=strlen(str); //计算字符串str的长度
printf("strlrn(str): %d ", inttemp);
return 0;
}
#include <stdio.h>
int main()
...{
char *str="sky2098,I like writing!";
int inttemp;
inttemp=strlen(str); //计算字符串str的长度
printf("strlrn(str): %d ", inttemp);
return 0;
}
在VC++ 6.0 编译运行:
- strlen函数
- strlen函数
- strlen() 函数
- strlen() 函数
- strlen函数
- strlen函数
- strlen函数
- strlen函数
- strlen函数
- strlen函数
- strlen函数
- strlen函数
- strlen函数 辨析
- 字符串函数strlen
- 微软strlen函数实现
- 实现strlen()函数
- strlen函数的实现
- strlen函数的实现
- ubuntu的相关问题~4
- 细节很重要!
- 在使用RowDataBound事件时犯的一个错误!
- WebBrower的应用和功能扩展(八)
- 对称加密算法的四种应用模式
- strlen函数
- JAVA和C++区别
- 使用FileFilter查找文件系统
- 一瞥港人的英文发音
- virtual abstract
- 使用JML改进你的Java程序
- C#继承小结
- Outlook 2003 教程 将自动响应更改为已读回执
- 我的股票:2007/03/15