Realated Questions
What will be the output of the following code snippet?
const obj1 = {first: 20, second: 30, first: 50}; console.log(obj1);
Which one of the following is correct output for the following given JavaScript code?
var obj= { length:20, height:35, } if('breadth' in obj === false) { obj.breadth = 12; } console.log(obj.breadth);
What will be the output of the following JavaScript code?
const obj1 = { property1:21 } const descriptor1 =Object.getOwnPropertyDescriptor(obj1,'property1'); console.log(descriptor1.configurable); console.log(descriptor1.enumerable);