Q. What will be the output of the following JavaScript code?
Code:<script>
try{
const cars = {
company: 'Honda'
};
Object.seal(cars);
delete cars.company;
document.write(cars.company);
}
catch (err){
document.write(err.message);
}
</script>
β
Correct Answer: (B)
Honda