The total average speed is the total distance divided by the total time.
We don't know the total length of the trip, but let's assume for simplicity that the whole distance is $100$ miles (we'll see that value doesn't matter in the end). Let's call the single distances $d_1,d_2,d_3$ where $d_1+ d_2 + d_3 = 100$. I'll denote the speeds by $v_i$ and the times by $t_i$ and we have $v_i = \frac{d_i}{t_i}$, i.e. $t_i = \frac{d_i}{v_i}$, $i=1,2,3$.
This means that Lucy is travelling
$$d_1 = 10 \mbox{ miles with a speed of } v_1= 56 \mbox{mph, i.e. for } t_1 = \frac{d_1}{v_1}= \frac{10}{56} \mbox{ hours}\\
d_2 = 10 \mbox{ miles with a speed of } v_2= 76\mbox{mph, i.e. for } t_2 = \frac{d_2}{v_2}= \frac{10}{76} \mbox{ hours}\\
d_3 = 80 \mbox{ miles with a speed of } v_2= 63\mbox{mph, i.e. for } t_3 = \frac{d_3}{v_3}= \frac{80}{63} \mbox{ hours}.$$
Thus, the (average) speed on the whole trip is the total distance divided by the total time:
$$v = \frac{10 + 10 + 80}{\frac{10}{56} +\frac{10}{76}+ \frac{80}{63}}.$$
This formula can be reformulated as $$v= \frac{1}{ 0.1\frac{1}{56} +0.1\frac{1}{76}+ 0.8\frac{1}{63}}=\frac{1}{ w_1\frac{1}{v_1} +w_2\frac{1}{v_2}+ w_3\frac{1}{v_3}},$$
where $w_1=w_2= 10 \%, w_3=80\%$. This kind of formula is called the weighted harmonic mean, which can be generally used to calculate the average speed. Here, we also see that the assumption that the whole distance is $100$ miles doesn't matter, as all that matters is the portion of the distance, i.e. $w_i = \frac{d_i}{d_1 + d_2 +d_3}$