algorithm 8.2 constructing a regular grammar without unit productions input: a regular grammar g = (v, xx, s, p) with unit productions output: a regular grammar g' = (v, xx, s, p), with c(g) = c(g')