Finite State Machine
A finite state machine (FSM) is an abstract model of computation consisting of a finite number of states, transitions between those states triggered by inputs, and a designated start state, used to represent systems that move through a limited set of well-defined conditions.
7 resources across 2 libraries
Glossary Terms(5)
Abstract Syntax Tree
An Abstract Syntax Tree (AST) is a tree-shaped data structure that represents the grammatical structure of source code, with each node corresponding to a const…
Lexical Analysis
Lexical analysis is the first phase of compiling or interpreting source code, in which a scanner (or lexer) reads raw characters and groups them into meaningfu…
Turing Machine
A Turing machine is a mathematical model of computation, introduced by Alan Turing in 1936, consisting of an infinite tape of cells, a read/write head, and a f…
Finite State Machine
A finite state machine (FSM) is an abstract model of computation consisting of a finite number of states, transitions between those states triggered by inputs,…
Regular Expression Theory
Regular expression theory is the branch of formal language theory that studies regular expressions — symbolic patterns used to describe regular languages — and…
Interview Questions(2)
Strategy vs State Pattern
The Strategy pattern lets a client choose an interchangeable algorithm at will and injects it into a context, while the State pattern lets an object change its…
How to Design a Vending Machine System?
A vending machine system is best modeled as a finite state machine with a small set of explicit states (idle, selecting, awaiting payment, dispensing, returnin…