Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- namespace ConsoleApplication1
- {
- class Program
- {
- static void Main(string[] args)
- {
- string test = "(a b)";
- char[] splitchars = new char[] {' ', '(', ')'};
- string[] splitted = test.Split(splitchars, StringSplitOptions.RemoveEmptyEntries);
- Console.WriteLine(splitted.Length);
- for (int i = 0; i < splitted.Length; i++)
- Console.WriteLine(splitted[i]);
- Console.ReadLine();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement