Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

find function in c++

// find function for strings
// my linkedin : https://www.linkedin.com/in/vaalarivan-prasanna-3a07bb203/
str = "Ilayathapathy";
subStr = "thalapathy";
cout << str.find(subStr, 1);  // prints 5 (first occurrence of substring 

// starting at index 1
 
PREVIOUS NEXT
Tagged: #find #function
ADD COMMENT
Topic
Name
2+9 =