{"ScriptPreparationCode":null,"TestCases":[{"Name":"foreach","Code":"const items = Array.from({length: 1000000}, () =\u003E Math.floor(Math.random() * 40));\r\nlet index = 0;\r\n\r\nitems.forEach(i =\u003E index\u002B\u002B);","IsDeferred":false},{"Name":"for-in","Code":"const items = Array.from({length: 1000000}, () =\u003E Math.floor(Math.random() * 40));\r\nlet index = 0;\r\n\r\nfor (let i in items) {\r\n index\u002B\u002B;\r\n}","IsDeferred":false},{"Name":"for-of","Code":"const items = Array.from({length: 1000000}, () =\u003E Math.floor(Math.random() * 40));\r\nlet index = 0;\r\n\r\nfor (let i of items) {\r\n index\u002B\u002B;\r\n}","IsDeferred":false},{"Name":"for","Code":"const items = Array.from({length: 1000000}, () =\u003E Math.floor(Math.random() * 40));\r\nlet index = 0;\r\n\r\nfor(let i = 0; i \u003C items.length; \u002B\u002Bi) {\r\n index\u002B\u002B;\r\n}","IsDeferred":false},{"Name":"optimized-for","Code":"const items = Array.from({length: 1000000}, () =\u003E Math.floor(Math.random() * 40));\r\nlet index = 0;\r\n\r\nfor(let i = items.length; i \u003E 0; --i) {\r\n index\u002B\u002B;\r\n}","IsDeferred":false}]}