Proper finitie state machine representation