Skip to content

Commit d386bfb

Browse files
correcting exercise 1.js
1 parent 1f6a0a3 commit d386bfb

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

  • Sprint-2/2-mandatory-errors

‎Sprint-2/2-mandatory-errors/1.js‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,9 @@
33
let age = 33;
44
age = age + 1;
55

6+
/*
7+
Answer : The Error is : TypeError: Assignment to constant variable.
8+
Constants in JavaScript can't be reassigned to correct this we have to change the varible type from const => let.
69
10+
*/
711
console.log(age)

0 commit comments

Comments
 (0)