Python Program to Convert Kilometers to Miles

in #python-dev5 years ago
# Taking kilometers input from the user
kilometers = float(input("Enter value in kilometers: "))

# conversion factor
conv_fac = 0.621371

# calculate miles
miles = kilometers * conv_fac
print('%0.2f kilometers is equal to %0.2f miles' %(kilometers,miles))

Coin Marketplace

STEEM 0.33
TRX 0.26
JST 0.040
BTC 97675.57
ETH 3609.37
USDT 1.00
SBD 3.31