{"ScriptPreparationCode":"\r\n var testData = {\r\nkeys: [\u0022ID\u0022, \u0022ID_CONTACT\u0022, \u0022ID_CHAT\u0022, \u0022DATE\u0022, \u0022TEXT\u0022, \u0022BLOB\u0022, \u0022$HDN_BIN_BLOB\u0022, \u0022HAS_BLOB\u0022, \u0022BLOB_TYPE\u0022, \u0022BLOB_DURATION\u0022, \u0022BLOB_SIZE\u0022, \u0022$HDN_DateTime\u0022, \u0022$HDN_XCoord\u0022, \u0022$HDN_YCoord\u0022, \u0022$HDN_ZCoord\u0022, \u0022$PK\u0022, \u0022$HDN_IDState\u0022, \u0022$HDN_DescState\u0022, \u0022$HDN_NumBlob\u0022],\r\nvalues: []\r\n};\r\n \r\n for (var i = 0; i \u003C 10000; i\u002B\u002B) {\r\n testData.values.push([\r\n \u0022ID\u0022, \r\n\u0022ID_CONTACT\u0022 \u002B i, \r\n\u0022ID_CHAT\u0022 \u002B i, \r\n\u0022DATE\u0022 \u002B i, \r\n\u0022TEXT\u0022 \u002B i, \r\n\u0022BLOB\u0022 \u002B i, \r\n\u0022$HDN_BIN_BLOB\u0022 \u002B i, \r\n\u0022HAS_BLOB\u0022 \u002B i, \r\n\u0022BLOB_TYPE\u0022 \u002B i, \r\n\u0022BLOB_DURATION\u0022 \u002B i, \r\n\u0022BLOB_SIZE\u0022 \u002B i, \r\n\u0022$HDN_DateTime\u0022 \u002B i, \r\n\u0022$HDN_XCoord\u0022 \u002B i, \r\n\u0022$HDN_YCoord\u0022 \u002B i, \r\n\u0022$HDN_ZCoord\u0022 \u002B i, \r\n\u0022$PK\u0022 \u002B i, \r\n\u0022$HDN_IDState\u0022 \u002B i, \r\n\u0022$HDN_DescState\u0022 \u002B i, \r\n\u0022$HDN_NumBlob\u0022 \u002B i\r\n ]);\r\n }","TestCases":[{"Name":"reduce","Code":"var customReduce = data =\u003E {\r\n var keys = data.keys;\r\n return data.values.map(x =\u003E {\r\n return x.reduce((acc, curr, i) =\u003E {\r\n acc[keys[i]] = curr;\r\n return acc;\r\n }, {})\r\n })\r\n}\r\n\r\ncustomReduce(testData)","IsDeferred":false},{"Name":"reduce2","Code":"function makeAnObject(data) {\r\n return data.values.reduce((arr, vals) =\u003E {\r\n return [\r\n ...arr,\r\n vals.reduce((obj, v, i) =\u003E ({ ...obj, [data.keys[i]]: v }), {})\r\n ]\r\n }, [])\r\n}\r\n\r\nmakeAnObject(testData)","IsDeferred":false}]}