Use the echo algorithm (Algorithm 6.5) to write an algorthm that computes a prefix labeling scheme (see Subsection 4.4.3) for an arbitrary network using $2|E|$ messages and $\mathrm{O}(N)$ time units.
Can you give an algorithm that computes the labeling scheme in $\mathrm{O}(D)$ time? ( $D$ is the diumeter of the network.)