Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- internal class Program
- {
- static void Main(string[] args)
- {
- string text = "Дана строка с текстом, используя метод строки String.Split() получить массив слов";
- char[] separators = { ' ', '.', ',', '(', ')' };
- string[] words = text.Split(separators, StringSplitOptions.RemoveEmptyEntries);
- foreach (string word in words)
- {
- Console.WriteLine(word);
- }
- Console.ReadKey();
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment