Technology, Software Engineering, Programming, Machine Learning, Data Science.
represent a graph. The idea is that the cell ‘ M[i][j] ’ represent the weight of going from node i to j. Adjacency Matrx PROS : Space efficient for representing dense graph. Edge weight lookup is O(1). Simplest graph representation. CONS : Requires O(V^2) Space. Iterating over all edges takes