so i have a range to compare and i am havning a hard time figuring out the code.
if the variable is
less than 18.5 then print Underweight
between 18.5 and 24.9 then print Normal
between 25 and 29.9 then print Overweight
30 or greater then print Obese
here is my code sofar
if(Num == 1){
System.out.print( "Enter Your wieght: " ); // prompt
weightLb = input.nextInt(); // read first number from user
System.out.print( "Enter Your hight: " ); // prompt
hightIn = input.nextInt(); // read second number from user
bmiS = (weightLb * 703)/(hightIn*hightIn); // body Mass Index in standared
if ( bmiS <= 18.4 ){
System.out.printf( "%s, %d, %s, which means your Underweight.", "Your BMI value is", bmiS );
}
if ( bmiS >= 30 ){
System.out.printf( "%s, %d, %s, which means your Obese.", "Your BMI value is", bmiS );
}
if ( bmiS < 24.9, bmiS > 18.5 ){
System.out.printf( "%s, %d, %s, which means your Normal.", "Your BMI value is", bmiS );
}
if ( bmis < 29.9, bmiS > 25){
System.out.printf( "%s, %d, %s, which means your Overweight.", "Your BMI value is", bmiS );
}
}