{"ScriptPreparationCode":null,"TestCases":[{"Name":"padStart","Code":"let x = 5;\r\nlet res = (\u0022\u0022 \u002B x).padStart(2, \u00220\u0022)","IsDeferred":false},{"Name":"splice","Code":"let x = 5;\r\nlet res = (\u00220\u0022 \u002B x).slice(-2)","IsDeferred":false},{"Name":"condition","Code":"let x = 5;\r\nlet res = x\u003C10 ? \u00600${x}\u0060 : \u0060${x}\u0060","IsDeferred":false},{"Name":"236236","Code":"function zeroPad(num, length) {\r\n let numStr = num.toString();\r\n let numZeros = length - numStr.length;\r\n \r\n if (numZeros \u003C= 0) {\r\n return numStr; // No padding needed\r\n }\r\n \r\n let padding = \u0027\u0027;\r\n while (numZeros \u003E 0) {\r\n // Use bitwise operations to efficiently append zeros\r\n padding \u002B= \u00270\u0027;\r\n numZeros--;\r\n }\r\n \r\n return padding \u002B numStr;\r\n}\r\n\r\nlet x = 5;\r\nlet res = zeroPad(x, 2);","IsDeferred":false}]}