Answers for "c++ string checking"

C++
4

check if character in string c++

std::string s = "hell[o";
if (s.find('[') != std::string::npos)
    ; // found
else
    ; //
Posted by: Guest on September-14-2020
1

c++ check substring

if (s1.find(s2) != std::string::npos) {
    std::cout << "found!" << '\n';
}
Posted by: Guest on July-07-2020

Code answers related to "c++ string checking"

Browse Popular Code Answers by Language