I want to turn an array or list of ints into a comma delimited string, like this:
string myFunction(List a) {
return string.Join(\",\", a);
}
Had a similar Extension Method that I modified to this
public static class MyExtensions
{
public static string Join(this List<int> a, string splitChar)
{
return string.Join(splitChar, a.Select(n => n.ToString()).ToArray());
}
}
and you use it like this
var test = new List<int>() { 1, 2, 3, 4, 5 };
string s = test.Join(",");
.NET 3.5