main -> 'a' main B | B A -> 'ab' B -> A | 'b'