How can I make the following grammar unambiguous
This is a typical ambiguous grammar for arithmetic expressions. You can write different unambiguous equivalent grammars. For example, if you use the traditional precedences and associativities;
$\begin{align*}
   E &amp;\to E + T \mid E - T \mid T \\
   T &amp;\to T * F \mid T / F \mid F \\
   F &amp;\to x \mid y \mid ( E )
\end{align*}$
You could also go the way of APL: All operations the same precedence, associate to the right.
$\begin{align*}
   E &amp;\to T + E \mid T - E \mid T * E \mid T / E \mid T \\
   T &amp;\to x \mid y \mid ( E )
\end{align*}$
The possibilities are almost endless.
To show the above aren't ambiguous isn't so easy.