Array.reverse()

From ZCubes Wiki
Jump to navigation Jump to search


Array.reverse(Function,StartValue)

Returns the reversed value of the given array.The first array element becomes the last, and the last array element becomes the first.But reverse() will change the original array value.

(1..10).reverse()

10 9 8 7 6 5 4 3 2 1


a=|3,2,1..10|;a.reverse();a;

5 6
3 4
1 2


See Also

backward

transpose