Type Your Code Here

var obj = { prop: function() {}, name: 'charry' }; // Creates an object named obj with a method prop and a property name initialized to 'charry' console.log(obj); // Logs the contents of obj to the console obj.name = 'karri'; // Changes the value of the name property of obj to 'karri' delete obj.prop; // Deletes the prop method from obj console.log(obj); // Logs the updated contents of obj to the console var o = Object.freeze(obj); // Freezes obj and assigns it to variable o obj.name = 'chris'; // Attempting to modify the name property of obj (which is frozen) - this modification won't occur console.log(obj); // Logs the contents of obj to the console

Output: