Draw a diagram of a right triangle.
Let h = height of dock (vertical side of right Δ)
12 ft = length of horizontal side of right Δ
2h + 3 = length of hypotenuse
By the Pythagorean Theorem, h2 + 122 = (2h + 3)2
h2 + 144 = 4h2 + 12h + 9
0 = 3h2 + 12h - 135
0 = (3h + 27) (h - 5)
h = -9 or h = 5. Since the height of the dock can't be negative, h = 5 ft.