http://stackoverflow.com/questions/33714963/c-sharp-deleting-array-elements-between-x-and-y

CSharp · Console

/Program.cs

using System;
using System.Linq;
					
public class Program
{
	public static void Main()
	{
		int[] array = {2, 6, 3, 6, 8, 2, 7, 2};
		int x = 2;
		int y = 4;
		
		var array1 = array.ToList()
		  .Take(x).Concat(array.ToList().Skip(x+y-1))
	      .ToArray();
		
			
		foreach(var i in array1)
		{
		  Console.Write(i);
		  Console.Write(',');
		}
	}
}
;