5
Interpret a Formal Grammar
Given a context-free grammar, and a string, parse the string using the formal grammar and output the matches for the non-terminals.
Examples
First line is string, following lines are grammar, then is the main grammar to parse, last line is output.
123
n -> any of
...