Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Program
- {
- //static string RandomString(int length)
- //{
- // const string chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789 ;.,/'!?<>{}[]:+-_=АБВГДЕЁЖЗИКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ";
- // var random = new Random();
- // return new string(Enumerable.Repeat(chars, length)
- // .Select(s => s[random.Next(s.Length)]).ToArray());
- //}
- static string ReplaceEnglishWords(string text)
- {
- string text1 = Regex.Replace(text, "([A-Z]|[a-z])+", "...");
- return text1;
- }
- static void Main(string[] args)
- {
- StreamReader fin = new StreamReader("input.txt");
- string text = fin.ReadToEnd();
- fin.Close();
- //string text = RandomString(100);
- string replaceText = ReplaceEnglishWords(text);
- Console.WriteLine(text);
- Console.WriteLine(replaceText);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement