CSharp examples for System:Array Slice
Remove First element from Array
// The .NET Foundation licenses this file to you under the MIT license. using System.Runtime.CompilerServices; using System.Collections.ObjectModel; using System.Collections.Generic; using System.Diagnostics.Contracts; public class Main{ public static T[] RemoveFirst<T>(this T[] array) {/*from ww w . java 2 s.c om*/ T[] result = new T[array.Length - 1]; Array.Copy(array, 1, result, 0, result.Length); return result; } }