Are you sure your algos returns correct results?
57,66 km is certainly more than 42% of the total.
42% is what you did, while 57,66 km is what is still missing (rounded it is equivalent to 58%). Hence, I'd tell the numbers are all right.