answersLogoWhite

0


Best Answer

Use a simple DFS/BFS traversal. If you have gone through all nodes, the graph is connected.

User Avatar

Wiki User

15y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How can you design an algorithm to check if a given graph is connected?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Design an algorithm for finding integer solutions for equations of the form x2 y2 n where n is some given positive integer Determine the time complexity of your algorithm?

yea me too dude. Mahleko :(


Write an algorithm to check whether the given number is odd or even?

Type your answer here... i think we should first enter 1 number then check it


What is complsexity of an algorithm?

Complexity of an algorithm is a measure of how long an algorithm would take to complete given


A Write the algorithm to concatenate two given strings?

a write the algorithm to concatenate two given string


What is devising of algorithms?

The algorithm is designed through algorithm engineering. The Algorithm design refers to one of the specific methods that is used in creating the mathematical process that is used in problem solving.


What has the author Charles H C Little written?

Charles H. C. Little has written: 'An algorithm for finding a canonical surface imbedding for a given planar connected graph'


Diagram used to represent an algorithm or sequence of actions in the form of boxes connected with arrows?

this is possibly a FLOW CHART given to me on another crossword puzzle site!! lamu lady


How do you use prim's algorithm to find a spanning tree of a connected graph with no weight on its edges?

Prims Algorithm is used when the given graph is dense , whereas Kruskals is used when the given is sparse,we consider this because of their time complexities even though both of them perform the same function of finding minimum spanning tree. ismailahmed syed


Why algorithm needs to solve programming problem?

This is the definition of an algorithm - a list of orders of how to solve a given programming problem.


You are given a list of students names and their tests scores Design an algorithm that does the following calculates the average test scores?

(x)/(y)=avg X= Total of Scores. Y= Total of Students.


What is Vector generation algorithm?

It is a basic algorithm for generating lines on computer screen. line is generated between given 2 endpoints


In term of computer science what is deterministic algorithm?

In computer science, deterministic algorithm is an algorithm which, given a particular input, always produces the same result. This is used to increase the efficiency of machines.