A binary code is entered into the program (For example: 10101001010100) you need to translate it into ASCII characters (string)

    1 answer 1

    Perhaps something will do.

    http://ideone.com/14GcZQ

    using System; using System.Text.RegularExpressions; public class Test { public static void Main() { var a = "10101001010100"; Console.WriteLine(Regex.Replace(a, "[01]{7}", m => ((char)Convert.ToByte(m.Value, 2)).ToString())); } } 

    But if productivity is important, you should think about another way.