I'm having trouble understanding how to convert this language to context free grammar.
$\{a^ib^jc^k\mid i > k, 0\le j \lt3, k \ge 0\}$
Part im getting stuck on is how to deal with a and c, whenever a c is added, you must also add an a, but with them at opposite ends of the string how do you properly build grammar for it? Since the below is not possible:
\begin{align} C &\rightarrow aC \\ C &\rightarrow c \end{align}
I've read the below post many times and tried to apply it but still not able to get it.
How to prove that a language is context-free?
Someone able to show me how this can be done?