Skip to content

Commit 0263d62

Browse files
committed
made the edits you pointed out
1 parent 9ee2adf commit 0263d62

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

Sprint-1/1-key-exercises/3-paths.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const base = filePath.slice(lastSlashIndex + 1);
1717
// Create a variable to store the ext part of the variable
1818

1919
const firstSlashIndex = filePath.indexOf("/");
20-
const dir = filePath.slice(firstSlashIndex + 1, lastSlashIndex +1);
20+
const dir = filePath.slice(firstSlashIndex, lastSlashIndex);
2121

2222
const lastdotindex = filePath.lastIndexOf(".");
2323
const ext = filePath.slice(lastdotindex);

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

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
// the times are in the wrong places ie:-20:53 is not a twelve hour time and as they are const they cant be directly changed
77

8-
let twelveHourClockTime = "13.00";
8+
let twelveHourClockTime = "13:00";
99
let twelthHour = twelveHourClockTime.substring(
1010
0,
1111
twelveHourClockTime.length - 3
@@ -15,7 +15,7 @@ let twelthHour = twelveHourClockTime.substring(
1515
let sufix =".AM"
1616

1717

18-
if (twelthHour => 13) {
18+
if (twelthHour >= 13) {
1919
twelthHour = twelthHour - 12;
2020
sufix =".PM"
2121

@@ -26,7 +26,7 @@ let twelthMinutes = twelveHourClockTime.substring(
2626
);
2727

2828

29-
let twentyFourHourClockTime = "08:53.pm";
29+
let twentyFourHourClockTime = "04:59.am";
3030
let twentyFour = twentyFourHourClockTime.substring(0,
3131
twentyFourHourClockTime.length -6)
3232
twentyFour = parseInt(twentyFour);

0 commit comments

Comments
 (0)