首页 > 其他 > 详细

strchr,wcschr 及strrchr, wcsrchr,_tcschr,_tcsrchr函数

时间:2014-10-31 13:29:35      阅读:390      评论:0      收藏:0      [点我收藏+]

       strchr,wcschr 及strrchr, wcsrchr,_tcschr,_tcsrchr函数

(1)

char *strchr( const char *string, int c );
wchar_t *wcschr( const wchar_t *string, wchar_t c );
Find a character in a string.
查找一个字符串中首次出现的指定字符。
Return Value

Each of these functions returns a pointer to the first occurrence of c in string(address), or NULL if c is not found.

 

 

_tcschr是strchr或者wcschr,跟_UNICODE是否定义有关(2)
char *strrchr( const char
*string, int c);
char *wcsrchr( const wchar_t *string, int c );

 

Scan a string for the last occurrence of a character.

查找一个字符串中最后出现的指定字符。
Return Value

Each of these functions returns a pointer to the last occurrence of c in string(address), or NULL if c is not found.
找出字符串中最后一个出现查找字符的地址,然后将该字符出现的地址返回。

 

_tcsrchr是strrchr或者wcsrchr,跟_UNICODE是否定义有关

 

strchr,wcschr 及strrchr, wcsrchr,_tcschr,_tcsrchr函数

原文:http://www.cnblogs.com/mengfanrong/p/4064729.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!