{"ScriptPreparationCode":"var arr = [];\r\nfor (let i = 0; i \u003C 100; i\u002B\u002B) {\r\n let internal = [];\r\n for (let j = 0; j \u003C 100; j\u002B\u002B) {\r\n internal.push(i * 100 \u002B j);\r\n }\r\n arr.push(internal);\r\n}\r\n","TestCases":[{"Name":"iterate / push","Code":"let flattened = [];\r\nfor (let i = 0; i \u003C arr.length; i\u002B\u002B) {\r\n let internal = arr[i];\r\n for (let j = 0; j \u003C internal.length; j\u002B\u002B) {\r\n flattened.push(internal[j]);\r\n }\r\n}\r\n","IsDeferred":false},{"Name":"reduce / spread","Code":"let flattened = arr.reduce((acc, i) =\u003E [ ...acc, ...i], []);","IsDeferred":false},{"Name":"reduce / concat","Code":"let flattened = arr.reduce((acc, i) =\u003E acc.concat(i), []);","IsDeferred":false},{"Name":"reduce / push","Code":"let flattened = arr.reduce((acc, i) =\u003E {\r\n i.forEach(e =\u003E acc.push(e));\r\n return acc;\r\n}, []);","IsDeferred":false},{"Name":"array.flat","Code":"let flattend = arr.flat();","IsDeferred":false},{"Name":"frray.flatMap","Code":"let flattend = arr.flatMap((x) =\u003E (x));","IsDeferred":false}]}