All pastes #448880 Raw Edit

Stuff

public java v1 · immutable
·published 2007-04-19 22:37 UTC
rendered paste body
package tpackage;import static tpackage.Conversions.*;public class TryConversions {	public double wattsToHP(double watts){	return watts * WATT_TO_HP;}public double hpToWatts(double hp){	return hp*HP_TO_WATT;}public double ouncesToGrams(double ounces){	return ounces*OUNCE_TO_GRAM;}public double poundsToGrams(double pounds){	return pounds * POUND_TO_GRAM;}public static void main(String[] args){	int myWeightInPounds = 180;	int myHeightInInches = 80;		TryConversions converter =  new TryConversions();		System.out.println("My weight in pounds " +  myWeightInPounds + "\t in grams:" + (int)converter.poundsToGrams(myWeightInPounds) );	}	}