We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5b6a38f commit 57e97e9Copy full SHA for 57e97e9
Sprint-1/2-mandatory-errors/4.js
@@ -1,2 +1,18 @@
1
-const 12HourClockTime = "20:53";
2
-const 24hourClockTime = "08:53";
+// const 12HourClockTime = "20:53";
+// const 24hourClockTime = "08:53";
3
+
4
+/**
5
+ * In javascript variable can't start with a number
6
+ * Can contain letters, digits (but not at the start), underscore _, and dollar signs $
7
+ *
8
+ * const 12HourClockTime = "20:53"; will cause a SyntaxError because variable names can't begin with a number.
9
10
+ * To fix it by changing the name to start with a letter.
11
+ */
12
13
+const twelveHourClockTime = "08:53";
14
+const twentyFourClockTime = "20:53";
15
16
+console.log(twelveHourClockTime);
17
+console.log(twentyFourClockTime);
18
0 commit comments