Skip to content

Commit 4da80d0

Browse files
committed
updated sprint 2
scaffold each script file with faded examples https://cafe.cognitiveload.com.au/kb/fadedworkedexamples
1 parent e5bda8c commit 4da80d0

File tree

22 files changed

+34
-121
lines changed

22 files changed

+34
-121
lines changed
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

Sprint-2/implement/bmi.js renamed to Sprint-2/3-mandatory-implement/1-bmi.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,7 @@
1313
// Given someone's weight in kg and height in metres
1414
// Then when we call this function with the weight and height
1515
// It should return their Body Mass Index to 1 decimal place
16+
17+
function calculateBMI(weight, height) {
18+
// return the BMI of someone based off their weight and height
19+
}

Sprint-2/implement/cases.js renamed to Sprint-2/3-mandatory-implement/2-cases.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,5 @@
1212
// Another example: "lord of the rings" should be "LORD_OF_THE_RINGS"
1313

1414
// You will need to come up with an appropriate name for the function
15-
// Use the string documentation to help you find a solution
15+
// Use the MDN string documentation to help you find a solution
16+
// This might help https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/toUpperCase
File renamed without changes.

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

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,7 @@ function formatTimeDisplay(seconds) {
88
const remainingMinutes = totalMinutes % 60;
99
const totalHours = (totalMinutes - remainingMinutes) / 60;
1010

11-
return `${pad(totalHours)}:${pad(remainingMinutes)}:${pad(
12-
remainingSeconds
13-
)}`;
11+
return `${pad(totalHours)}:${pad(remainingMinutes)}:${pad(remainingSeconds)}`;
1412
}
1513

1614
// You will need to play computer with this example - use the Python Visualiser https://pythontutor.com/visualize.html#mode=edit
@@ -19,13 +17,18 @@ function formatTimeDisplay(seconds) {
1917
// Questions
2018

2119
// a) When formatTimeDisplay is called how many times will pad be called?
20+
// =============> write your answer here
2221

2322
// Call formatTimeDisplay with an input of 61, now answer the following:
2423

2524
// b) What is the value assigned to num when pad is called for the first time?
25+
// =============> write your answer here
2626

2727
// c) What is the return value of pad is called for the first time?
28+
// =============> write your answer here
2829

2930
// d) What is the value assigned to num when pad is called for the last time in this program? Explain your answer
31+
// =============> write your answer here
3032

3133
// e) What is the return value assigned to num when pad is called for the last time in this program? Explain your answer
34+
// =============> write your answer here

0 commit comments

Comments
 (0)