Skip to content

Commit 8c269ba

Browse files
committed
fix: variable name to display the time
1 parent 89a42ab commit 8c269ba

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

Sprint-1/errors/4.js

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,11 @@
1-
const 12HourClockTime = "20:53";
2-
const 24hourClockTime = "08:53";
1+
2+
// explanation: the first lines will throw an error because js detect a number instead of a variable name,
3+
// so we move the number to the end and now it works fine.
4+
// const 24hourClockTime = "08:53;
5+
// const 12HourClockTime = "20:53";
6+
7+
8+
const clock12h = "20:53";
9+
const clock24h = "08:53";
10+
console.log(clock12h);
11+
console.log(clock24h);

0 commit comments

Comments
 (0)