I have made a square and have a diagonal along the middle. I want to label the bottom side, right side, and the diagonal to show the Pythagorean identity. So the sides should be, 1,1, and square root respectively. How would I add this in the code?
\begin{tikzpicture}
\draw (0,0) -- (4,0) -- (4,4) -- (0,4) -- (0,0) ;
\draw (0,0) -- (4,4);
\end{tikzpicture}