Skip to content

Commit d911165

Browse files
committed
explaining the error
1 parent 570b271 commit d911165

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

  • Sprint-2/2-mandatory-errors

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

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ const twentyFourHourClockTime = "20:53";
77
// 2. Check if the time is in the "pm" period. If it is, add 12 to the hours (unless it's 12pm).
88
// 3. If the time is in the "am" period and the hour is 12, set the hour to 0.
99
// 4. Format the hours and minutes into a string in 24-hour format.
10+
// The error is SyntaxError: Invalid or unexpected token, because a variable name cannot start with a digit.

0 commit comments

Comments
 (0)