Data structures are used to store and organize data.
Graph is a primary non-linear data structure,which can solve many real world problems of programming.
There are 2 main parts of graph.
There are 2 main parts of graph.
1. Vertices where the data is stored
2. Edges that connect the Vertices
Undirected Graph
Unlike Tree, graph has loops. Tree is used to represent hierarchical
data.
Few practical applications are
- Social network connectivity finder(User is the node and edge is the relationship between users)
- Google maps
- Computer Networks
Different Types of graphs:
1 Directed Graph Weighted graph
Undirected Graph
Once we model data into a graph, there are standard
algorithms to solve different problems.