Find the value of x and y. Write the answers in simplest radical formx= y=

Let's redraw the traingle
if the altitude is drawn to the hypotenuse of a right triangle, then the two triangles formed are similar to the original triangle and to each other. ∆CBD ~ ∆ABC, ∆ACD ~ ∆ABC, and ∆CBD ~ ∆ACD.
This means that
[tex]\begin{gathered} \frac{BD}{CD}=\frac{CD}{AD} \\ \\ \frac{AB}{CB}=\frac{CB}{DB} \end{gathered}[/tex]Replacing
[tex]\begin{gathered} \frac{3}{x}=\frac{x}{9} \\ \\ x^2=27 \\ x=\sqrt{27}=3\sqrt{3} \end{gathered}[/tex][tex]\begin{gathered} \frac{12}{y}=\frac{y}{3} \\ \\ y^2=36 \\ y=\sqrt{36}=6 \end{gathered}[/tex]