Skip to content

Commit d8f561b

Browse files
reset file Sprint-2/3-mandatory-implement/1-bmi.js
1 parent f45625e commit d8f561b

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

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

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,5 @@
1515
// It should return their Body Mass Index to 1 decimal place
1616

1717
function calculateBMI(weight, height) {
18-
// squaring your height: 1.73 x 1.73 = 2.99
19-
let heightSquared = height * height;
20-
// dividing 70 by 2.99 = 23.41
21-
let weightMod = weight / heightSquared;
22-
// Your result will be displayed to 1 decimal place, for example 23.4.
23-
let BMI = weightMod.toFixed(1);
2418
// return the BMI of someone based off their weight and height
25-
return BMI;
2619
}
27-
28-
let myWeight = 70;
29-
let myHeight = 1.73;
30-
31-
console.log(`my BMI is ${calculateBMI(myWeight, myHeight)}`);

0 commit comments

Comments
 (0)