using System.Text.RegularExpressions;
public static void Main()
var sensitiveWords = new System.Collections.Generic.List<String>()
string[] specialChar = { "+", "-", "*", "(", ")" };
sensitiveWords = sensitiveWords.Select(s =>
foreach (var specChar in specialChar)
rv = rv.Replace(specChar, @"\" + specChar);
foreach (string sw in sensitiveWords)
Regex r = new Regex("(^" + sw + "$)|(^" + sw + "[^a-z])|([^a-z]" + sw + "[^a-z])|([^a-z]" + sw + "$)");
Console.WriteLine( r.Match(text).Success + "," + sw );