This preview shows page 1. Sign up to view the full content.
Unformatted text preview: S feetString = JOptionPane.showInputDialog ("Enter a number in feet: "); ( feet = Double.parseDouble(feetString); f inches = feet * INCHES_IN_FOOT; i JOptionPane.showMessageDialog(null, feet + " feet is " + inches + " inches."); f String inchesString = JOptionPane.showInputDialog ("Now, enter a whole number in inches: "); ( wholeInches = Integer.parseInt(inchesString); w feet = wholeInches / INCHES_IN_FOOT; f JOptionPane.showMessageDialog(null, wholeInches + " inches is " + feet + " feet."); w System.exit(0); } }...
View Full Document
This note was uploaded on 03/05/2011 for the course CSCI 384 taught by Professor Drchan during the Spring '11 term at CA Health Sciences.
- Spring '11