File tree Expand file tree Collapse file tree
Sprint-2/4-mandatory-interpret Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -21,18 +21,18 @@ function formatTimeDisplay(seconds) {
2121// Questions
2222
2323// a) When formatTimeDisplay is called how many times will pad be called?
24- // =============> write your answer here
25-
26- // Call formatTimeDisplay with an input of 61, now answer the following:
24+ // =============> 3 times
2725
2826// b) What is the value assigned to num when pad is called for the first time?
29- // =============> write your answer here
27+ // =============> 0
3028
31- // c) What is the return value of pad is called for the first time?
32- // =============> write your answer here
29+ // c) What is the return value of pad when it is called for the first time?
30+ // =============> "00"
3331
34- // d) What is the value assigned to num when pad is called for the last time in this program? Explain your answer
35- // =============> write your answer here
32+ // d) What is the value assigned to num when pad is called for the last time in this program? Explain your answer
33+ // =============> 1, because formatTimeDisplay(61) has 1 remaining second,
34+ // and the last call to pad is pad(remainingSeconds).
3635
37- // e) What is the return value of pad when it is called for the last time in this program? Explain your answer
38- // =============> write your answer here
36+ // e) What is the return value of pad when it is called for the last time in this program? Explain your answer
37+ // =============> "01", because pad adds a zero to the beginning of "1"
38+ // to make it two characters long.
You can’t perform that action at this time.
0 commit comments