Skip to content
open roadmaps
All Roadmaps
Practice Mix
Docker
Linux & CLI
Data Structures & Algorithms
Git
Python
JavaScript
SQL
Web basics
Home
/
JavaScript
/
Closures & Encapsulation
/ Test
Closures & Encapsulation Test
Question 1 of 4
What is a closure in JavaScript?
1.
A function that retains access to its outer lexical scope variables even after the outer function has finished executing
2.
A method that closes a database connection
3.
A syntax error that prevents script execution
4.
A command that closes the browser window
Tip: Press 1-4 on keyboard to select.
Check Answer