Anthony Olajide
Jan 2, 2026 at 2:56 PM
Sign in to join the conversation
[s]```[/s]
const weight = prompt("Enter your weight");
const height = prompt("Enter your height");
const bmiCalc = () => {
const bmi = weight / Math.pow(height, 2);
return `Your BMI is ${bmi}kg/m^2`;
};
alert(bmiCalc());
```