Project 2
This commit is contained in:
@@ -0,0 +1,9 @@
|
|||||||
|
//1 inch = 2.54 centimetres.
|
||||||
|
//2.2046 pounds in a kilo
|
||||||
|
let inches = 72;
|
||||||
|
let pounds = 180;
|
||||||
|
let weight = pounds / 2.2046; // in kilos
|
||||||
|
let height = inches * 2.54; // height in centimetres
|
||||||
|
console.log(weight, height);
|
||||||
|
let bmi = weight/(height/100*height/100);
|
||||||
|
console.log(bmi);
|
||||||
Reference in New Issue
Block a user