# WOW, you rock. It came out to 73. I need to round it to one decimal place though, and that should be 73.5. Would I just take off the Int and do math.round(centimeters,1)? nm

Posted by atulb84 (93 se) on September 17, 2004 at 14:33:33: In Reply to: Geez, I think I need to retake my programming classes :wall: posted by Will on September 17, 2004 at 13:09:49: : totalinches = ((63360 * miles) + (36 * yards) + (12 * feet) + (inches)) : totalmeters = totalinches / 39.37 : kilometers = Int(totalmeters / 1000) : meters = totalmeters mod 1000 : centimeters = Int((meters mod 1)*100) : meters = int(meters) : The last 3 lines are all u need from your original code. Replys:

Name: |
E-Mail |
Car: |
Subject |
Message:
: : totalinches = ((63360 * miles) + (36 * yards) + (12 * feet) + (inches)) : : totalmeters = totalinches / 39.37 : : kilometers = Int(totalmeters / 1000) : : meters = totalmeters mod 1000 : : centimeters = Int((meters mod 1)*100) : : meters = int(meters) : : The last 3 lines are all u need from your original code.