fix infinite recursive call & change initial state of the example