How to remove empty strings a.k.a (lambda, epsilon) from a LR(0) grammar Say I have the following grammar:

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


I need to build the finite state machine with the LR(0) items, 

But I know in order to do this I have to remove the λ. 

How to I accomplish this ? 

Also, after I have the SLR(1) table, how to  I prove is valid ?

Thanks, I'm studying for an exam, and I'm stuck here :(
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