{"ScriptPreparationCode":"var a = {a:{b:{c:20}}};","TestCases":[{"Name":"lodash","Code":"let result = _.get(a, \u0027a.b.c\u0027, \u0022\u0022);","IsDeferred":false},{"Name":"mine","Code":"const get = (mainObj, path, def=null) =\u003E {\r\n let newPath = path.replace(/\\[/g,\u0027.\u0027).replace(/\\]/g, \u0027.\u0027).split(\u0027.\u0027);\r\n newPath.forEach(path=\u003E{\r\n mainObj = mainObj[path] \r\n });\r\n\r\n if(mainObj === undefined || mainObj === null){\r\n return def\r\n }\r\n\r\n return mainObj;\r\n};\r\n\r\nconst result = get(a, \u0027a.b.c\u0027, \u0022\u0022);","IsDeferred":false}]}