The mutable array-like object of interest.
The index of the first element in the range to be
reversed, inclusive. The default value is 0. Negative values
are taken as an offset from the end of the array.
The index of the last element in the range to be
reversed, inclusive. The default value is -1. Negative values
are taken as an offset from the end of the array.
Linear.
A start or stop index which is non-integral.
import { ArrayExt } from '@lumino/algorithm';
let data = [0, 1, 2, 3, 4];
ArrayExt.reverse(data, 1, 3); // [0, 3, 2, 1, 4]
ArrayExt.reverse(data, 3); // [0, 3, 2, 4, 1]
ArrayExt.reverse(data); // [1, 4, 2, 3, 0]
Generated using TypeDoc
Reverse an array in-place.