If you want to know if someone understands scope then you should ask about scope, not conceal a bug that relates to the topic you are interested in.
"Tricky" is the correct word here and tricky interview questions are stupid.
"Tricky" is the correct word here and tricky interview questions are stupid.
How would you ask about this issue in interviews?
It's much more difficult to understand this theoretically than when encounter this while you code.