Solution (source code)

= Solution

Write $L=d(x,y)$. If $m'$ is any other metric midpoint, apply the inequality from (a) to the chosen midpoint $m$ with $z=m'$. The right side is $\tfrac12(L/2)^2+\tfrac12(L/2)^2-L^2/4=0$, so $m=m'$. \b[Every pair has a unique midpoint.]

Choose successive midpoints to define $\gamma(k/2^n)$ on all dyadic parameters. Consecutive points at level $n$ have distance $L/2^n$. The <triangle inequality> gives $d(\gamma(s),\gamma(t))\leq(t-s)L$ for dyadic $s<t$. Conversely,
$$
L\leq d(x,\gamma(s))+d(\gamma(s),\gamma(t))+d(\gamma(t),y)
\leq sL+d(\gamma(s),\gamma(t))+(1-t)L,
$$
which gives the reverse bound. Thus equality holds. Completeness extends this map uniquely and continuously to $[0,1]$, retaining $d(\gamma(s),\gamma(t))=|s-t|L$. It is a constant-speed <geodesic>.

Every other <geodesic> has the same midpoint, and then the same successive midpoints, so agrees on all dyadic parameters. <Continuity> gives agreement everywhere. Hence $\boxed{\text{there is exactly one geodesic segment between any two points}.}$