strengthen point

1. splice(), slice() methods

      (1)、arrayObject.splice(index,howmany,item1,.....,itemX)

       Add/remove items to/from an array, then return the removed item

           Note: This method will change the original array

     (2)、arrayObject.slice(start,end)

        Returns the selected element from an existing array

            Returns a new array containing the elements in arrayObject from start to end (excluding this element)

            Note: This method does not modify the array, but returns a subarray

     

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326528513&siteId=291194637