11.
How can you avoid global scope pollution?
12.
What is the purpose of the global object in JavaScript?
13.
Which of the following can create a global variable?
14.
What keyword is used to ensure a variable is block-scoped?
15.
In Node.js, what is the global object called?
16.
Which of the following methods can help in avoiding global variables?
17.
What is the output of typeof window in a browser environment?
18.
What is the output of console.log(globalThis === window); in a browser environment?
19.
What happens if you declare a variable inside a function with the same name as a global variable?
20.
How can you access a global variable inside a function if it has the same name as a local variable?