CLS
REM Declare Varibles
DIM MILES, YARDS, FEET, INCHES AS DOUBLE
DIM KM, METER, TINCH AS DOUBLE
DIM CM, TMETER AS DOUBLE
REM INPUT THE DATA
INPUT "ENTER THE DISTANCE IN MILES", MILES
INPUT "ENTER THE DISTANCE IN YARDS", YARDS
INPUT "ENTER THE DISTANCE IN FEET", FEET
INPUT "ENTER THE DISTANCE IN INCHES", INCHES
REM CONVERT INTO TOTAL INCHES
TINCH = 63360 * MILES + 36 * YARDS + 12 * FEET + INCHES
REM CONVERT INTO TOTAL METER
TMETER = TINCH / 39.37
REM CONVERT TO KILOMETER
KM = INT(TMETER / 1000)
REM CONVERT TO METER
METER = INT(TMETER - KM * 1000)
REM CONVERT TO CENTIMETER
CM = (TMETER - (KM * 1000) - METER) * 100
REM PRINT DETAILS
PRINT "KILOMETER", KM
PRINT "METER", METER
PRINT "CENTIMETER", CM;