class Program { //GetLength(1)-столбцы static void Main(string[] args) { Console.WriteLine("Enter string:"); StringBuilder strB = new StringBuilder(Console.ReadLine()); byte[] CountCh = new byte[65536]; for (int i = 0; i < strB.Length; i++) CountCh[strB[i]]++; char chMax = (char)Array.IndexOf(CountCh, CountCh.Max()); strB = strB.Replace(chMax.ToString(), ""); Console.WriteLine(strB); } }