forked from algorithm-visualizer/algorithm-visualizer
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdesc.json
More file actions
23 lines (23 loc) · 1.18 KB
/
desc.json
File metadata and controls
23 lines (23 loc) · 1.18 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
"BFS": "Breadth-first search (BFS) is an algorithm for traversing or searching tree or graph data structures. It starts at the tree root (or some arbitrary node of a graph, sometimes referred to as a 'search key') and explores the neighbor nodes first, before moving to the next level neighbors.",
"Applications": [
"Copying garbage collection, Cheney's algorithm",
"Finding the shortest path between two nodes u and v, with path length measured by number of edges (an advantage over depth-first search)",
"Testing a graph for bipartiteness",
"(Reverse) Cuthill–McKee mesh numbering",
"Ford–Fulkerson method for computing the maximum flow in a flow network",
"Serialization/Deserialization of a binary tree vs serialization in sorted order, allows the tree to be re-constructed in an efficient manner.",
"Construction of the failure function of the Aho-Corasick pattern matcher."
],
"Complexity": {
"time": "worst $O(|E|)$",
"space": "worst $O(|V|)$"
},
"References": [
"<a href='https://en.wikipedia.org/wiki/Breadth-first_search'>Wikipedia</a>"
],
"files": {
"tree": "Searching a tree",
"shortest_path": "Finding the shortest path"
}
}