using System; using System.Text.RegularExpressions; public class Test { public static void Main() { // your code goes here var regex = new Regex(@"![\P{Cc}\P{Cn}\P{Cs}]"); var matches = regex.Matches("Hello, World!" + (char)4); Console.WriteLine("Results: " + matches.Count); foreach (Match match in matches) { Console.WriteLine("Result: " + match); } } }