Check02C - output.print("Height in ft['in]:...

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

View Full Document Right Arrow Icon
import java.util.Scanner; import; import type.lib.*; public class Check02C { public static void main(String[] args) { String height = ""; int weight; double bmi; Scanner input = new Scanner(; 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

This note was uploaded on 09/16/2011 for the course CSE CSE 1020 taught by Professor Burton,ma during the Fall '10 term at York University.

Ask a homework question - tutors are online