Answer
$x=42~ft$
Work Step by Step
Let h be the vertical distance between the sailor's eye and the top of the lighthouse: $h=49~ft-14~ft=35~ft$
$tan~\theta=\frac{h}{d}$
$d=\frac{h}{tan~\theta}=\frac{35~ft}{tan~30.0°}=61~ft$
This is how far the ship is from the lighthouse.
Let x be the distance from the ship to the rocks.
$x=61~ft-19~ft=42~ft$