C# 中如何将List<string>里的集合转换成字符串并按指定的字符进行分隔?

代码:
using System;
using System.Collections.Generic;
publicclassMyClass
{
publicstaticvoidMain()
{
List<string> names =newList<string>(){"ccc","xxx","aaa","bbbb"};
names.Sort();
var result =String.Join(",", names.ToArray());
Console.Write(result);
Console.ReadKey();
}
}

 

 





posted @ 2014-11-18 17:23  HTL  阅读(11198)  评论(0编辑  收藏  举报
htl