我想把一个字符串放入数组,假设我有一个像string a = "dog cat horse mouse"
这样的字符串,所以我想把这个字符串放入一个数组中,就像它出现在字符串中一样单独工作。字符串到数组
string array [0]=dog
string array [1]=cat
string array [2]=horse
string array [3]=mouse
或类似这样的
string array= {"dog", "Cat", "mouse", "horse"};
我希望它像这样的数组,所以:)
MSDN是你的朋友。用它。接近它。然后让我补充它。 – 2011-02-15 15:43:08