{"ScriptPreparationCode":"var seed = Date.now();\r\n\r\nvar twoDigits = [];\r\n\r\nfor(let i = 0; i\u003C100; i\u002B\u002B) {\r\n\ttwoDigits.push(String(i).padStart(2, \u00270\u0027));\r\n}\r\n\r\nvar threeDigits = [];\r\n\r\nfor(let i = 0; i\u003C1000; i\u002B\u002B) {\r\n\tthreeDigits.push(String(i).padStart(3, \u00270\u0027));\r\n}\r\n\r\nfunction toISO1(x) {\r\n Number.isFinite(x);\r\n\r\n const time = new Date(x);\r\n \r\n const year = String(time.getUTCFullYear());\r\n const mo = twoDigits[time.getUTCMonth()\u002B1];\r\n const da = twoDigits[time.getUTCDate()];\r\n const ho = twoDigits[time.getUTCHours()];\r\n const mi = twoDigits[time.getUTCMinutes()];\r\n const se = twoDigits[time.getUTCSeconds()];\r\n const mil = threeDigits[time.getUTCMilliseconds()];\r\n \r\n return \u0060${year}-${mo}-${da}T${ho}:${mi}:${se}.${mil}Z\u0060;\r\n}\r\n\r\nfunction toISO2(x) {\r\n\treturn new Date(x).toISOString();\r\n}","TestCases":[{"Name":"template strings and padding","Code":"var value = toISO1(seed);","IsDeferred":false},{"Name":"toISOString()","Code":"var value = toISO2(seed);","IsDeferred":false}]}