Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

Copy an Array

let shallowCopy = fruits.slice() // this is how to make a copy
// ["Strawberry", "Mango"]
Source by developer.mozilla.org #
 
PREVIOUS NEXT
Tagged: #Copy #Array
ADD COMMENT
Topic
Name
2+3 =