1. Engineering
  2. Computer Science
  3. given the adjacency matrix of a graph g design an...

Question: given the adjacency matrix of a graph g design an...

Question details

Given the adjacency matrix of a graph G, design an O(n2) algorithms that prints YES if G is a star and NO otherwise. Kindly note the solution must contain a nested loop to scan through all the adjacency matrix to find if the graph is a star or not.

Solution by an expert tutor
Blurred Solution
This question has been solved
Subscribe to see this solution