I'm new to python and trying to build a 10k running calculator from the exercises in "Think Python"
what I'm trying to do is break down the input time ie:43.12 into 2 separate numbers ... then perform (43x60)- which gives the seconds and then add the remaining seconds +12 .. to give the accurate number to work from ..
below is running it if i hardcode 4312 in as a whole number - but what id like to to accept it dynamically ... can somebody help point me in the right direction
#python 10k calculator
import time
distance = 6.211180124223602
time = float(input("what was your time?"))
tenK = 10
mile = 1.61
minute = 60
sph = 0
def convertToMiles():
global distance
distance = tenK / mile
convertToMiles()
print("Distance equal to :",distance)
def splitInput():
test = [int(char) for char in str(4312)]
print(test)
splitInput()
inputto get the time value.