is there any stl containers which will return the number of multiple occurence of a word in a string ??
example :
line : hello world hello hello
word : hello
output : 3
thanks in advance :)
No, however there are functions that can fetch the sub-string of a string. Using those functions, you can figure out how many sub-strings there are.
http://cplusplus.com/reference/string/string/find/