so i want to know how many "yy" in this string of characters "yyysadljhyysady"
so how do i do this is c
example would be nice
so i want to know how many "yy" in this string of characters "yyysadljhyysady"
so how do i do this is c
example would be nice
did you start by looking at the "string.h" header file? is there something in it to, say, find a substring?
As nadroj was hinting at, you can use strstr to find the first substring. Increment the pointer it returns and repeat until it returns NULL.