Count occurrences of a substring: Difference between revisions

Content added Content deleted
Line 41:
#include <string.h>
 
int match(const char *s, const char *p, int overlap)
{
int c = 0, l = strlen(p);