{"ScriptPreparationCode":"const data = Array.from({ length: 10000 }, (_, i) =\u003E (i \u003C 101 ? -1 : 1));\r\n// Optional: Shuffle to make it realistic\r\n// data.sort(() =\u003E Math.random() - 0.5);\r\n","TestCases":[{"Name":"reduce","Code":"const count = data.reduce((acc, val) =\u003E val \u003C 0 ? acc \u002B 1 : acc, 0);\r\n","IsDeferred":false},{"Name":"filter","Code":"const count = data.filter(item =\u003E item \u003C 0).length;\r\n","IsDeferred":false},{"Name":"for...of","Code":"let count = 0;\r\nfor (const item of data) {\r\n if (item \u003C 0) {\r\n count\u002B\u002B;\r\n }\r\n}","IsDeferred":false},{"Name":"forEach","Code":"let count = 0;\r\ndata.forEach(item =\u003E item \u003C 0 \u0026\u0026 count\u002B\u002B);","IsDeferred":false}]}