Check the picture below.
let's find the "y + x" distance first, and let's then find the "y" distance, if we subtract "y" from "y + x", we'll know how many kilometers it travelled in 2 hours, from 3pm to 5pm, and thus its speed.
![\tan(25^o )=\cfrac{\stackrel{opposite}{2.5}}{\underset{adjacent}{y+x}} \implies (y+x)\tan(25^o)=2.5 \\\\\\ y+x=\cfrac{2.5}{\tan(25^o)}\implies \boxed{y+x\approx 5.36} \\\\[-0.35em] ~\dotfill\\\\ \tan(40^o )=\cfrac{\stackrel{opposite}{2.5}}{\underset{adjacent}{y}} \implies y\tan(40^o)=2.5\implies y=\cfrac{2.5}{\tan(40^o)}\implies \boxed{y\approx 2.98} \\\\[-0.35em] ~\dotfill\\\\ 5.36-2.98\approx 2.38\hspace{5em}\cfrac{2.38~km s}{2~hrs} ~~ \approx ~~ \text{\LARGE 1.2}~(km)/(hr)](https://img.qammunity.org/2024/formulas/mathematics/college/pop7b6h54y1a10vv0mu5me21rp6wbh554v.png)
Make sure your calculator is in Degree mode.