Answers for "c++ " in string"

C++
19

string in cpp

// Include the string library
#include <string>

// Create a string variable
string greeting = "Hello";
Posted by: Guest on October-01-2020
4

c++ string contains

if (string1.find(string2) != std::string::npos) {
    std::cout << "found!" << 'n';
}
Posted by: Guest on April-02-2020

Browse Popular Code Answers by Language