answersLogoWhite

0


Best Answer

Both algoritms can be build very similary. The difference between breadth-first search and depth-first search is order in which elements ar added to OPEN list. In breadth-first search new nodes are appended to the end of OPEN list

In depth-first search new nodes are inserted in the begining of OPEN list

User Avatar

Wiki User

15y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is the difference between breadth first search and depth first search in C programming?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Basic Math

What is the difference between basic and advanced searches?

Well despite the obvious differences in vocabulary, Basic: Brings up anything with a key word in it.Advanced: It searches with a concious cybermind to find exactly what you are looking for.


What is the difference between primitive and non primitive data structure?

A primitive data structure is generally a basic structure that is usually built into the language, such as an integer, an array or a linked-list.A non-primitive data structure is built out of primitive data structures linked together in meaningful ways, such as a binary search tree, AVL Tree, Hashtable, etc.


Complexity of linear search?

the compexity of linear search in worst case is f(n) = n+1


Write a short note on linear search?

Linear search, also known as sequential search, is a process that checks every element in the list sequentially until the desired element is found. The computational complexity for linear search is O(n), making it generally much less efficient than binary search (O(log n)). But when list items can be arranged in order from greatest to least and the probabilities appear as geometric distribution (f (x)=(1-p) x-1p, x=1,2),then linear search can have the potential to be notably faster than binary search.


Which pairs of prime numbers have difference of 2?

(3, 5), (5, 7), (11, 13), (17, 19), (29, 31), (41, 43), (59, 61), (71, 73)...Many more are known. Search the Internet for "twin primes". It is not known whether there are infinitely many twin primes.

Related questions

Difference between breadth first and depth first search in artificial intelligence?

diference between depth first search and breath first search in artificial intelellegence


Breadth First search is used in?

stacks


What is the advantage of iterative deepening search over depth-first?

Iterative deepening effectively performs a breadth-first search in a way that requires much less memory than breadth-first search does. So before explaining the advantage of iterative deepening over depth-first, its important to understand the difference between breadth-first and depth-first search. Depth first explores down the tree first while breadth-first explores all nodes on the first level, then the second level, then the third level, and so on. Breadth-first search is ideal in situations where the answer is near the top of the tree and Depth-first search works well when the goal node is near the bottom of the tree. Depth-first search has much lower memory requirements. Iterative deepening works by running depth-first search repeatedly with a growing constraint on how deep to explore the tree. This gives you you a search that is effectively breadth-first with the low memory requirements of depth-first search. Different applications call for different types of search, so there's not one that is always better than any other.


What is the difference between blind search and heuristic search?

Heuristic search algorithms have knowledge of where the goal or finish of the graph. For example, in a maze, they would know which path leads in the direction of the goal. Blind search algorithms have no knowledge of where the goal is, and wander "blindly" through the graph. Blind search techniques include Breadth-first, Depth-first search, etc. Heuristic search techniques include Best-first, A*, etc.


Is breadth first search bidirectional?

It can be. It depends on the structure and how it is implemented.


How to detect binary search tree as depth first search or breadth first search?

O(N-1)


What is the difference between a boolean search and a keyword search?

A keyword search searches for exact word when a boolean search looks for synonym's. The difference between a keyword search and a boolean search is the focus of the search. A keyword search is a search for an exact word. A boolean search is a search for a synonym.


Difference between research method and search model?

A research method refers to the approach or technique used to conduct a study, encompassing procedures for data collection, analysis, and interpretation. On the other hand, a search model pertains to a theoretical framework that outlines the process by which information is retrieved and selected in a search process. While research methods deal with the overall research design, search models specifically focus on information retrieval processes.


What is the difference between WikiAnswers and Google Search?

Google search - is a search engine. WikiAnswers is a forum.


8 Queens Problem using Breadth First Search and Depth First Search?

1 3


What is the difference between a search service and a search engine?

really...........nothing. there the same..


What is the difference between ethical value and value?

search