Distance and duration

Hello,

During a request to the API I have a return of a Json file with a duration of 39.7 and a distance of 217.8. :open_mouth:
How to transform the duration into 4min (39.7-> 4min) and the distance into 2.3kms (217.8 → 2.3 kms)

Thank you