How to remove empty strings a.k.a (lambda, epsilon) from a LR(0) grammar
Find all nullable variables. In this case only E' is nullable. 
Let me illustrate the second step with an example:


Replace a production A -> BCD with a family of productions like this (assuming B, C &amp; D are nullable):

A -&gt; BCD | BC | BD | CD | B | C | D



Delete all the productions with the empty string as the right-hand side.


With all that in mind we get:

E  -&gt; TE' | T
E' -&gt; +TE'| -TE' | +T | -T
T  -&gt; (E) |  id