A state machine is a sort of automation that executes with a limited number of states. It can enter a state when triggered by an activity and exit that state when triggered by another activity. Transitions are another significant feature of state machines since they allow you to add criteria to jump from one state to another. Arrows or branches are used to depict between the states.