string[] array = "A,B,C,D,,EF".Split(new char[] { ',' });
string[] array = "A,B,C,D,,EF".Split(new char[] { ',' }, StringSplitOptions.None);
string[] array = "A,B,C,D,,EF".Split(new string[] { "," }, StringSplitOptions.None);
傳回值不包括包含空字串的陣列元素
string[] array = "A,B,C,D,,EF".Split(new char[] { ',' }, StringSplitOptions.RemoveEmptyEntries);
string[] array = "A,B,C,D,,EF".Split(new string[] { "," }, StringSplitOptions.RemoveEmptyEntries);
沒有留言:
張貼留言