Although you are on the right track, you chose the wrong triangle. The one you chose is not a right triangle, which is why your answer is wrong.
The following works much more easily:
^2=(3-r)^2+4$ and in turn the answer, $r=\frac9{10}$.