Depth-first search is different from breadth-first search, Computer Engineering

Assignment Help:

Depth-first search is different from Breadth-first search in the following ways:

A depth search traversal method goes to the deepest level of the tree first and then works up whereas a breadth-first search looks at all possible paths at the similar depth before it goes to a deeper level. When we come to a dead end in a depth-first search, we back up as little as possible. We try another route from a new vertex-the route on top of our stack. In a breadth-first search, we require to back up as far as possible to find a route originating from the previous vertices. So the stack is not an appropriate structure for finding a previous route because it keeps track of things in the order opposite of their occurrence-the latest route is on top. To keep track of things in the order in which they happened, we use a FIFO queue.

 


Related Discussions:- Depth-first search is different from breadth-first search

What are the general security issues, What are the General Security Issues ...

What are the General Security Issues Many issues exist when linking a computer system to the Internet or indeed to an external link via a network set up. There are numerous way

Data phases - computer architecture, Data phases: After the address ph...

Data phases: After the address phase (particularly, starting with the cycle that DEVSEL# goes low) comes a burst of one or more data phases. In all the cases, initiator drives

DFD, Define software architecture and describe which types of architectures...

Define software architecture and describe which types of architectures can be used in Email or Facebook applications

What is a c++ class, Class is a user-defined data type in C++. It can be fo...

Class is a user-defined data type in C++. It can be formed to solve a particular kind of problem. After creation the user require not know the specifics of the working of a class.

What is a match code, What is a Match Code? Match code is a tool to hel...

What is a Match Code? Match code is a tool to help us to find for data records in the system. Match Codes are an proficient and user-friendly search aid where key of a record i

Explain handle graphics in matlab, This is the MATLAB graphics system. It c...

This is the MATLAB graphics system. It contains high-level commands for two-dimensional and three-dimensional data visualization, image processing, animation, and presentation grap

What are the types of smart cards used in e-commerce, What are the types of...

What are the types of Smart cards used in e-commerce? Generally there are 2 types of smart cards. Memory smart cards, which can be sighted as minuscule removable read/ write

What is monkey testing, What is Monkey testing? The monkey testing is ...

What is Monkey testing? The monkey testing is the process of testing here and there for judging the application trying to observe the accessing dissimilar functionalities is i

Discuss in detail about micro computer, Discuss in detail about Micro compu...

Discuss in detail about Micro computer A microcomputer's CPU is a microprocessor. The microcomputer was originated in late 1970s. The first microcomputer was built around 8-bit

What is external procedures, Q. What is External Procedures? These proc...

Q. What is External Procedures? These procedures are written as well as assembled in separate assembly modules and afterwards linked together with the main program to form a bi

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd