def best_time(time1, time2):
    """Return the best of two given times."""
    time = min(time1, time2)
    if time == 0:
        return max(time1, time2)  # if no time yet --> set the highest
    return time