Skip to content
Closed
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
bafaee8
answered sprint-2 0.js
iteddy16 Jun 13, 2025
ea11210
answered 1-key-errors 1.js
iteddy16 Jun 13, 2025
9b714c8
answered 1-key-errors 2.js
iteddy16 Jun 13, 2025
9b5c5d4
answered 2-mandatory-debug 0.js
iteddy16 Jun 13, 2025
1640e2c
update 0.js
iteddy16 Jun 13, 2025
1537baf
answered 2-mandatory-debug 1.js
iteddy16 Jun 13, 2025
d79a1ca
answered 2-mandatory-debug 2.js
iteddy16 Jun 13, 2025
7a35859
answered 3-mandatory-implement / 1-bmi.js
iteddy16 Jun 13, 2025
6b2be6c
answered 3-mandatory-implement/2-cases.js
iteddy16 Jun 13, 2025
dc3b4e8
update 3-mandatory-implement/3-to-pounds.js
iteddy16 Jun 13, 2025
aa1f8ee
answered 4-mandatory-interpret/time-format.js
iteddy16 Jun 13, 2025
62bba09
update 5-stretch-extend
iteddy16 Jun 13, 2025
95332ed
Updated Sprint-2/ 1.js
iteddy16 Jun 24, 2025
01079c2
Update Sprint-3\2\2-is-proper-fraction.js
iteddy16 Jun 24, 2025
e4425d9
Update 2-is-proper-fraction.test.js
iteddy16 Jun 24, 2025
de2a5de
updated Sprint-3\2\3-get-card-value and test.js
iteddy16 Jun 24, 2025
e3ebe30
update sprint-3\3\count.js and count.test.js
iteddy16 Jun 24, 2025
6e88202
update sprint-3\3\get-ordinal-number.js
iteddy16 Jun 24, 2025
376d990
Add additional test cases for getOrdinalNumber function
iteddy16 Jun 24, 2025
1593416
update Sprint-3\3\repeat.js and repeat.test.js
iteddy16 Jun 24, 2025
ba26a99
Revert "Update Sprint-3\2\2-is-proper-fraction.js"
iteddy16 Jun 24, 2025
9a7b904
Update for review mandatory debug 2.js
iteddy16 Jul 3, 2025
09838ac
updated for review mandatory implement 2-cases.js
iteddy16 Jul 3, 2025
e7ceb40
updates for review mandatory implement 3-to-pound.js
iteddy16 Jul 3, 2025
46a7807
updated for review mandatory-interpret time-format.js
iteddy16 Jul 3, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
answered 3-mandatory-implement / 1-bmi.js
  • Loading branch information
iteddy16 committed Jun 13, 2025
commit 7a35859c82924dfd7689accc2fb392eed62c4b3b
9 changes: 7 additions & 2 deletions Sprint-2/3-mandatory-implement/1-bmi.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,10 @@
// It should return their Body Mass Index to 1 decimal place

function calculateBMI(weight, height) {
// return the BMI of someone based off their weight and height
}
const bmi = weight / (height * height);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good.

return bmi.toFixed(1); // Round to 1 decimal place
// # Calculate BMI by dividing weight by height squared
// return the BMI of someone based off their weight and height
}
// Example usage:
console.log(`Your BMI is ${calculateBMI(70, 1.73)}`); // Should log: Your BMI is 23.4