「 cat」= * cat、c*at、ca*t、cat*. 私のコードは.
次に例を示します。
string s = "the cat is here with the cagt";
int count;
string[] words = s.Split(' ');
foreach (var item in words)
{
if(///check for "cat")
{
count++;
return count; (will return 2)
}
}