How do closures enable Data encapsulation/ Data Privacy
Difficulty: 5/10
closures, data encapsulation, module pattern
Closures enable encapsulation and data hiding, allowing you to create modules with private variables and methods. This is a fundamental aspect of the Module Pattern in JavaScript, which helps prevent accidental external access to internal data.