\documentclass[11pt]{article}
\usepackage{amsmath,amssymb,amsthm,tabu,enumerate,tikz,verbatim}
\usetikzlibrary{automata,positioning}
\usepackage[margin=1in]{geometry}

\title{\vspace{-3ex}\bf Context-Free Grammars\\[2ex]
\rm\normalsize CS 311, Fall 2015}
\date{}
\author{}

\begin{document}
\maketitle

\paragraph{Exercise 1} Write a context-free grammar for each of the following languages.
\begin{enumerate}[a)]
    \item $\{ w \;|\; w = a^nb^{3n}, n \geq 0\}$
    \vspace{35ex}
    \item $\{ a^ib^jc^k \;|\; j > i+k\}$
    \vspace{35ex}
    \item $\{ a^nb^mc^2n \;|\; n,m \geq 0 \}$
\end{enumerate}

\newpage

\paragraph{Exercise 2} Write a context-free grammar for each of the following languages.
\begin{enumerate}[a)]
    \item $\{ w \;|\; w \text{ contains at least three 1s} \}$, $\Sigma = \{0,1\}$
    \vspace{40ex}
    \item $\{ w \;|\; \text{The length of $w$ is odd} \}$, $\Sigma = \{a,b\}$
    \vspace{40ex}
    \item $\{ w \;|\; w = a^ib^jc^k, i = j \}$, $\Sigma = \{a,b,c\}$
\end{enumerate}


\begin{comment}
\paragraph{Exercise 2} Convert the following grammar into Chomsky Normal Form.
\begin{align*}
    A &\rightarrow BaBaB  \\
    B &\rightarrow aB | bB | \varepsilon
\end{align*}
\end{comment}
\end{document}
