Junior — Senior
Context is lost when assigning a method to a variable
livecode
Task condition
It is necessary to fix the code so that when calling the function fn(), the correct context of the object obj is preserved and the value 1 is output to the console.
const obj = {
a: 1,
say() {
console.log(this.a);
}
};
const fn = obj.say;
fn();