Ask your AI Ask your AI to turn this code into a guided bug-finding exercise.
Claude ChatGPT I am reading "Given `function read() { return this.name }`, what does `read.call({ name: "Lin" })` return?" on CodeWiki (https://codewiki.com/practice/mcq/javascript/checkpoint-2/checkpoint-2-call-output/).
Context (verbatim from the page):
"""
Given `function read() { return this.name }`, what does `read.call({ name: "Lin" })` return?
`"Lin"`
`undefined`, because detached functions cannot receive `this`
The function object itself
"""
Introduce three subtle bugs into the example above and let me find them. Reveal each answer only after I have guessed.
Answer in English. Keep code examples in JavaScript. Where you are unsure, say so.