Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

arry suffle javascript

const shuffle = a => {
    for (let i = a.length; i; i--) {
        let j = Math.floor(Math.random() * i);
        [a[i - 1], a[j]] = [a[j], a[i - 1]];
    }
}
shuffle(arry);
 
PREVIOUS NEXT
Tagged: #arry #suffle #javascript
ADD COMMENT
Topic
Name
5+1 =