FOR FREE YEAR SOLVED

Write regular expression for the machine M1

 

 

Now we calculate the regular expression of final which is initial state itself. If initial state is final state then λ is accepted by machine.

 

It is better to calculate it by left hand loop resolve because final state is left hand state.

We are taking longest loop, regular expression RE = (a + ba)*