{"ScriptPreparationCode":"var class17 = document.getElementsByClassName(\u002217\u0022);\r\nObject.prototype.closestParent = function(tag, multi) {\r\n var el=this.parentNode; var newTag = tag.slice(1); var g = 0; \r\n if(tag[0] === \u0022.\u0022){while(el \u0026\u0026 g \u003C multi){if(el.className !== newTag){g\u002B\u002B;el=el.parentNode;}else{return el};}};\r\n if(tag[0] === \u0022#\u0022){while(el \u0026\u0026 g \u003C multi){if(el.id !== newTag){g\u002B\u002B;el=el.parentNode;}else{return el};}}; \r\n};\r\n","TestCases":[{"Name":"closest method","Code":"for(i=0;i\u003C100;i\u002B\u002B){\r\n console.log(class17[0].closest(\u0022#helloWorld\u0022))\r\n}","IsDeferred":false},{"Name":"closestParent function","Code":"for(i=0;i\u003C100;i\u002B\u002B){\r\n console.log(class17[0].closestParent(\u0022#helloWorld\u0022, 1))\r\n}","IsDeferred":false}]}