22 - Graphs and Trees
adjacency list: A list of nodes connected by an edge from a given node.
adjacency list: A list of nodes connected by an edge from a given node.
adjacency matrix: A matrix describing the edges connecting all pairs of nodes.
adjacency matrix: A matrix describing the edges connecting all pairs of nodes.
binary search tree: A binary tree in which the nodes contain items ordered such that for any node, the left descendants are all smaller items and right descendants are all larger items.
binary search tree: A binary tree in which the nodes contain items ordered such that for any node, the left descendants are all smaller items and right descendants are all larger items.
binary tree: A tree in which each node will have at most two children.
binary tree: A tree in which each node will have at most two children.
child node: A node that is reachable by an edge from a given node and that is one level farther away from the root node.
child node: A node that is reachable by an edge from a given node and that is one level farther away from the root node.
connected graph: A graph in which there is some sequence of edges connecting every pair of nodes.
connected graph: A graph in which there is some sequence of edges connecting every pair of nodes.
cycle: A sequence of edges that, when followed, returns to the starting node.
cycle: A sequence of edges that, when followed, returns to the starting node.
directed edge: An edge that connects from a source node to a destination node.
directed edge: An edge that connects from a source node to a destination node.
edge: A connection between two nodes. Edges can be weighted or unweighted.
edge: A connection between two nodes. Edges can be weighted or unweighted.
graph: A data structure used to store items and their relationships to each other. Items are stored at nodes, and the relationships between items are stored by edges connecting nodes.
graph: A data structure used to store items and their relationships to each other. Items are stored at nodes, and the relationships between items are stored by edges connecting nodes.
indirection: When an intermediate structure is used to describe a connection between two entities. For example, rather than storing a list of entities, instead there might be a list of indices stored, with the entities stored in a separate structure found by examining each index.
indirection: When an intermediate structure is used to describe a connection between two entities. For example, rather than storing a list of entities, instead there might be a list of indices stored, with the entities stored in a separate structure found by examining each index.
node: A vertex in a graph that is used to store information about the items or entities. Nodes are connected by edges
node: A vertex in a graph that is used to store information about the items or entities. Nodes are connected by edges
parent node: A node in a tree that is one edge closer to the root than a given node.
parent node: A node in a tree that is one edge closer to the root than a given node.
root: A node in a tree designated as the one from which all other nodes will be traced.
root: A node in a tree designated as the one from which all other nodes will be traced.
tree: A particular type of connected graph that does not contain a cycle. One of the most widely used data structures; many algorithms have been developed just for trees
tree: A particular type of connected graph that does not contain a cycle. One of the most widely used data structures; many algorithms have been developed just for trees
undirected edge: An edge that connects two nodes, with no distinction for a source and destination.
undirected edge: An edge that connects two nodes, with no distinction for a source and destination.
weight: A value stored along an edge, indicating something about the relationship between the nodes it connects.
weight: A value stored along an edge, indicating something about the relationship between the nodes it connects.