52
rated 0 times
[
57]
[
5]
/ answers: 1 / hits: 19519
/ 15 Years ago, mon, october 5, 2009, 12:00:00
How do I shift an array of items up by 4 places in Javascript?
I have the following string array:
var array1 = [t0,t1,t2,t3,t4,t5];
I need a function convert array1 to result in:
// Note how t0 moves to the fourth position for example
var array2 = [t3,t4,t5,t0,t1,t2];
Thanks in advance.
More From » arrays