I will start by writing the ratio as a fraction: $\frac{x}{y}=\frac{1}{2}$. Then I will cross-multiply to get rid of the fractions: $2x=y$. Now I have an equation that relates $x$ and $y$. I can use this equation to substitute for $y$ in the other given equation: $y=4x-36$. Substituting $2x$ for $y$, I get: $2x=4x-36$. Simplifying this equation, I subtract $2x$ from both sides and add $36$ to both sides: $36=2x$. Dividing both sides by $2$, I get: $x=18$. 
The ratio of $x$ to $y$ is $1$ to $2$. What is the value of $x$ if $y=4x-36$?