{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Check02C - output.print"Height in ft'in" height =...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
import java.util.Scanner; import java.io.PrintStream; import type.lib.*; public class Check02C { public static void main(String[] args) { String height = ""; int weight; double bmi; Scanner input = new Scanner(System.in); PrintStream output = System.out;
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: output.print("Height in ft['in]: "); height = input.nextLine(); output.print("Weight in lb [>0]: "); weight = input.nextInt(); bmi = ToolBox.getBMI(weight, height); output.printf("The BMI is %.1f \n", bmi); } }...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online