string [] ss =s.Split(new Char('+'));
-----------------------
msdn上的例子:
public class SplitTest {
public static void Main() { string words = "this is a list of words, with: a bit of punctuation."; string [] split = words.Split(new Char [] {' ', ',', '.', ':'}); foreach (string s in split) { if (s.Trim() != "")
Console.WriteLine(s);
}
}
}
-----------------------
msdn上的例子:
public class SplitTest {
public static void Main() { string words = "this is a list of words, with: a bit of punctuation."; string [] split = words.Split(new Char [] {' ', ',', '.', ':'}); foreach (string s in split) { if (s.Trim() != "")
Console.WriteLine(s);
}
}
}
ss[0] = "旅游业";
ss[1] ="电子技术";
ss[2] = "法律";
ss[3] ="";