shuffle a 1D array via mutation. the ordering of elements will be randomized by the end.