Skip to content

Commit 345f9a2

Browse files
committed
adjusted to fix the decimal place within the function.
1 parent ebb51e5 commit 345f9a2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ let height = 1.73; // in metres
2020
function calculateBMI(weight, height) {
2121
// return the BMI of someone based off their weight and height
2222
let bmi = weight / (height * height);
23-
return bmi;
23+
return bmi.toFixed(1);
2424
}
2525

26-
console.log(calculateBMI(weight, height).toFixed(1)); // should return 26.7
26+
console.log(calculateBMI(weight, height)); // should return 26.7

0 commit comments

Comments
 (0)