A Linq based solution might be one line of code:
using System;
using System.Linq;
public class Program
{
public static void Main()
{
Console.WriteLine("Hello World");
int[] ints = "1,2,3,4,666".Split(',').Select(s => int.Parse(s)).ToArray();
foreach (int i in ints)
{
Console.WriteLine(i);
}
}
}
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony "Common sense is so rare these days, it should be classified as a super power" - Random T-shirt AntiTwitter: @DalekDave is now a follower!