[tex]x = lungimea \;drumului \\ \frac{1}{2}x - \frac{2}{5}x = 50 \\ \\ x(\frac{1}{2} - \frac{2}{5})=50 \\ \\ x(\frac{5}{10} - \frac{4}{10})=50 \\ \\ x(\frac{5-4}{10} )=50 \\ \\ \frac{1}{10}x=50 \\ \\ \frac{x}{10}=50 \\ \\ x=50*10 = \boxed{500 \; m}[/tex]