[Solved] What could be the best way of extracting substrings of varying length in c#


        int[] array = new int[] { 2, 4, 8, 3, 3 };
        List<string> someList = new List<string>();
        int j = 0;

        for (int i = 0; i < array.Length; i ++)
        {
            string str = delta.Substring(j, array[i]);
            someList.Add(str);
            j += str.Length;
        }

solved What could be the best way of extracting substrings of varying length in c#