In the following code, state and nextstate are integers with a range of 0 to 2.
![1347_c3200026-892f-49fe-b17f-4d92fe7dd072.png](https://secure.tutorsglobe.com/CMSImages/1347_c3200026-892f-49fe-b17f-4d92fe7dd072.png)
![2152_787f734a-bc81-4789-b756-26eee017fb6a.png](https://secure.tutorsglobe.com/CMSImages/2152_787f734a-bc81-4789-b756-26eee017fb6a.png)
(a) Explain why a latch would be created when the code is synthesized.
(b) What signal would appear at the latch output?
(c) Make changes in the code which would eliminate the latch.