首页
学习
活动
专区
工具
TVP
发布
精选内容/技术社群/优惠产品,尽在小程序
立即前往

std::char_traits::find

static const char_type* find( const char_type* p, std::size_t count, const char_type& ch );

(until C++17)

static constexpr const char_type* find( const char_type* p, std::size_t count, const char_type& ch );

(since C++17)

搜索字符ch在第一个count所指向的序列的字符p...

参数

p

-

pointer to a character string to search

count

-

the number of characters to analyze

ch

-

the character to search for

返回值

指定范围内的第一个字符的指针。[p, p + count)相当于ch,或NULL如果找不到。

例外

%280%29

复杂性

线性在count...

代码语言:txt
复制
 © cppreference.com

在CreativeCommonsAttribution下授权-ShareAlike未移植许可v3.0。

扫码关注腾讯云开发者

领取腾讯云代金券