joe-smith submitted these extension methods

  • Slice<T>(int start, int end)

    Returns the range of elements between the specified start and end indexes. Negative numbers count from the end, rather than the start, of the sequence. Values of 'end' larger than the actual sequence are truncated and do not cause index-out-of-bounds exceptions. Functionally very similar to Python's list[x:y] slices.
    C# System.Collections.Generic.IEnumerable<T> Joe Smith