{"ScriptPreparationCode":"const arr = [];\r\nconst arr2 = [];\r\nfor (let i = 0; i \u003C 10000; i\u002B\u002B) {\r\n arr.push([i, \u0027Val\u0027 \u002B i]);\r\n arr2.push([\u0027key\u0027 \u002B i, \u0027Val\u0027 \u002B i]);\r\n}\r\n\r\nvar map1 = new Map(arr)\r\nvar map2 = new Map(arr2)\r\n\r\nconst arr3 = [];\r\nfor (let i = 0; i \u003C 1000; i\u002B\u002B) {\r\n arr3.push([\u0027key2\u0027 \u002B i, \u0027Val\u0027 \u002B i]);\r\n}\r\nvar map9 = new Map(arr3)","TestCases":[{"Name":"Merge spread","Code":"var map3 = new Map([...map1, ...map2]);","IsDeferred":false},{"Name":"merge foreach","Code":"var map4 = new Map(map1)\r\nmap2.forEach((val, key) =\u003E {map4.set(key, val)})","IsDeferred":false},{"Name":"merge 2 foreach","Code":"var map4 = new Map()\r\nmap1.forEach((val, key) =\u003E {map4.set(key, val)})\r\nmap2.forEach((val, key) =\u003E {map4.set(key, val)})","IsDeferred":false},{"Name":"update big map","Code":"map9.forEach( (val,key) =\u003E {map1.set(key,val)})","IsDeferred":false}]}