Which one of the following options is the correct output for the given code of JavaScript?
var person =
{
name: "James",
getName:function()
{
nreturnthis.name;
}
}
varunboundName=person.getName;
varboundName=unboundName.bind(person);
document.writeln(boundName());
a) James
b) compilation error
c) runtime error
d) undefined