Skip to main content


Command Description

Slices the array from a specified range of point and returns the slice

Command Prototype

arrRet = splice(array,begin,end)

Parameter Description

arrayTrueexpression[]Need to get the array elements of an array
beginTruenumber0The start position of the sliced element
endTruenumber0The index number representing the end of the slice


arrRet,The variable used to save the output of the command.


TracePrint("----------------------Intercept array------------- -") 
//[Remarks] Delete and return the first element of the array.
//Input parameter 1:
// array--The array that needs to intercept the elements of the array.
//Input parameter 2:
// begin--The starting position of the element to be intercepted.
//Input parameter 3:
// end--The end position of the element to be intercepted.
//out parameters:
// arrRet--The variable to which the output of the function call is saved.
//Command prototype: arrRet=splice(array,begin,end)