Do for a badge #697
-
What is the difference between let, const, and var in JavaScript? |
Beta Was this translation helpful? Give feedback.
Answered by
JohnnelBaylen
Mar 23, 2025
Replies: 1 comment
-
var: Function-scoped, can be re-declared and updated. let: Block-scoped, can be updated but not re-declared in the same scope. const: Block-scoped, cannot be re-declared or updated. |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
Dem0-Test
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
var: Function-scoped, can be re-declared and updated.
let: Block-scoped, can be updated but not re-declared in the same scope.
const: Block-scoped, cannot be re-declared or updated.