Skip to content

Commit 6f10d48

Browse files
committed
Resolved merge conflict in time-format.js
1 parent 8416a21 commit 6f10d48

File tree

1 file changed

+4
-7
lines changed

1 file changed

+4
-7
lines changed

Sprint-2/4-mandatory-interpret/time-format.js

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,6 @@ function formatTimeDisplay(seconds) {
1111
return `${pad(totalHours)}:${pad(remainingMinutes)}:${pad(remainingSeconds)}`;
1212
}
1313

14-
// You will need to play computer with this example - use the Python Visualiser https://pythontutor.com/visualize.html#mode=edit
15-
// to help you answer these questions
16-
1714
// Questions
1815

1916
// a) When formatTimeDisplay is called how many times will pad be called?
@@ -24,11 +21,11 @@ function formatTimeDisplay(seconds) {
2421
// b) What is the value assigned to num when pad is called for the first time?
2522
// =============> 0
2623

27-
// c) What is the return value of pad is called for the first time?
24+
// c) What is the return value of pad when it is called for the first time?
2825
// =============> "00"
2926

30-
// d) What is the value assigned to num when pad is called for the last time in this program? Explain your answer
27+
// d) What is the value assigned to num when pad is called for the last time in this program? Explain your answer
3128
// =============> 1. The last pad call is pad(remainingSeconds), and with 61 seconds input, remainingSeconds = 61 % 60 = 1
3229

33-
// e) What is the return value assigned to num when pad is called for the last time in this program? Explain your answer
34-
// =============> "01". pad(1) calls toString() to get "1", then padStart(2, "0") pads it to "01"
30+
// e) What is the return value of pad when it is called for the last time in this program? Explain your answer
31+
// =============> "01". pad(1) calls toString() to get "1", then padStart(2, "0") pads it to "01"

0 commit comments

Comments
 (0)