← BYTES
Algorithms·Starter·Ref: 12.1.10
What distinguishes a graph from a tree as a data structure?
Have a question about this video? Mention reference 12.1.10 when you contact us.
a.A graph is just another name for a tree
b.Trees can have more than one root node while graphs cannot
c.Graphs can only store numbers while trees can store any data
d.A tree is a special, restricted kind of graph with no cycles and exactly one path between any two nodes; a general graph can have cycles and multiple paths between nodes
Every tree is technically a graph, but a tree is specifically a connected, acyclic graph (no cycles, exactly one path between any pair of nodes). A general graph relaxes both constraints -- it may contain cycles and multiple distinct paths connecting the same two nodes.
Find this on YouTube & Instagram
Every BYTES video is tagged with its reference number and topic — search any of these on YouTube or Instagram to find this one:
#BYTES#BYTES12110#Algorithms