Mealy machines
State machines where output depends on current state and input. Mealy machines typically require fewer states than Moore machines for equivalent behavior. Output is associated with transitions.
Formula
λ(state, input) = output
Real World
A contactless payment terminal acts like a Mealy machine: the same 'idle' state produces different outputs (approve or decline) depending on whether the card input has sufficient funds.
Exam Focus
Label outputs on transitions (arrows), not inside state circles — this distinguishes Mealy from Moore in diagrams.
How well did you know this?