BFS

Technology & Computing abbreviation · Programming

BFS
Stands forBreadth-first search
CategoriesTechnology & Computing

BFS stands for Breadth-first search, a programming abbreviation.

A graph traversal algorithm that visits all neighbors of a node before moving further away, using a queue. In unweighted graphs it finds shortest paths, which makes it useful for routing, puzzles and social-network distances.

Example: BFS from the start cell gives the minimum number of moves through the grid.

Usage notes

Konrad Zuse described the idea in 1945, and Edward F. Moore published it in 1959 for finding shortest paths through mazes. It uses more memory than depth-first search because it stores the whole frontier. Dijkstra's algorithm generalizes it to weighted graphs.

More programming abbreviations

  • ASCII – American Standard Code for Information Interchange
  • AST – Abstract syntax tree
  • awk – Aho, Weinberger and Kernighan
  • Bash – Bourne Again Shell
  • BASIC – Beginner's All-purpose Symbolic Instruction Code
  • BDD – Behavior-driven development
  • BNF – Backus-Naur form
  • BST – Binary search tree
  • CD – Continuous delivery
  • chmod – Change mode
  • CI – Continuous integration
  • CI/CD – Continuous integration and continuous delivery (or deployment)

See all 154 programming abbreviations →