We know that a²+b²=c²
So if you follow the pythagorean theorem, we substitute the hypotenuse for c² and the leg (12) for either a² or b² because a and b are both legs, so it doesn't matter.
now we have a²+12²=13²
But I usually take the shortcut..and instead of a²+12²=13²
I subtract 12² from 13² (it's the same thing)
After you subtract 13²-12²=a²...you find the square root of 13²-12²
so the answer is LaTeX: a=\sqrt{13^2-12^2}
a= square root of 13²-12²