javascript Global Scope in 3 minutes

Опубликовано: 02 Июнь 2026
на канале: MAI
6
0

Global Scope: Variables declared outside any function have a global scope.
var globalVar = "I am global"; // Can be accessed anywhere in the code
Local Scope: Variables declared inside a function are local to that function.