Answer
The lengths of the legs are $5$ and $12$ meters.
Work Step by Step
Recall that in a right triangle, the sum of the squares of the lengths of the two legs is equal to the square of the length of the hypotenuse, which can be expressed as:
$$(leg)^{2} + (leg)^{2} = (hypotenuse)^{2} \:or\: a^{2} + b^{2} = c^{2}$$
Thus,
$$a = b-7$$ $$c=13$$ $$a^{2} + b^{2} = c^{2}$$ $$( b-7)^{2} + b^{2} = 13^{2}$$ $$b^2-14b+49+b^2=169$$ $$2b^2-14b+49=169$$
Subtract $169$ from both sides:
$$2b^2-14b+49-169=169-169$$ $$2b^2-14b-120=0$$
Divide the whole equation by $2$:
$$b^2-7b-60=0$$
Factor:
$$(b+5)(b-12)=0$$
$$b+5=0 \: or \: b-12=0$$ $$b=-5$$ $$b=12$$
Since the length cannot be negative, therefore leg $b$ is equal to $12$ meters.
$$a=b-7$$ $$a=12-7$$ $$a=5$$
Thus, leg $a$ is equal to $5$ meters.
Check:
$$a^{2} + b^{2} = c^{2}$$ $$5^{2} + 12^{2} = 13^{2}$$ $$25 + 144 = 169$$ $$169=169$$