What will be the output of the following code?
const obj1 = { name: "John", age: 30 };
const obj2 = Object.assign({}, obj1);
obj2.name = "Jane";
console.log(obj1.name);
What will be the output of the following code?
const obj1 = { name: "John", age: 30 };
const obj2 = Object.assign({}, obj1);
obj2.name = "Jane";
console.log(obj1.name);