{"ScriptPreparationCode":"const generateRandomString = () =\u003E Math.random().toString(36).substring(7);\r\n\r\n// Create the currentList object with a long listElements array\r\nconst currentList = {\r\n field1: generateRandomString(),\r\n field2: generateRandomString(),\r\n field3: generateRandomString(),\r\n listElements: Array.from({ length: 10000 }, () =\u003E generateRandomString()),\r\n};\r\nlet valuesList = [];\r\nfor (let i = 0; i \u003C 100; i\u002B\u002B){\r\n \r\nvaluesList[i] = Math.floor(Math.random() * currentList.listElements.length)\r\n}","TestCases":[{"Name":"splice check","Code":"function spliceOperation() {\r\n let innerJ = 0;\r\n for (let i = 0 ; i \u003C valuesList.length; i\u002B\u002B){\r\n \r\n innerJ = valuesList[i];\r\n currentList.listElements.splice(innerJ, 1);\r\n }\r\n}","IsDeferred":false},{"Name":"splice spread","Code":"function sliceSpreadOperation() {\r\n let innerJ = 0;\r\n for (let i = 0 ; i \u003C valuesList.length; i\u002B\u002B){\r\n innerJ = valuesList[i];\r\n currentList.listElements = [\r\n ...currentList.listElements.slice(0, innerJ),\r\n ...currentList.listElements.slice(innerJ \u002B 1),\r\n ];\r\n }\r\n}","IsDeferred":false}]}