If I have the following CFG, which is just the regex [0-9]+:
STATEMENT -> NUMBER
NUMBER -> NUMBER DIGIT
NUMBER -> DIGIT
DIGIT -> 0|1|2|3|4|5|6|7|8|9
How do I turn it into Chomskey Normal Form? It seems like its going to be impossible without using a NUMBER -> epsilon rule.
Thanks!
The Chomsky normal form for the grammar is:
I don't know why this didn't occur to me earlier.