
BFS DFS
Authored by Dhilip Kumar V TTS2750
Computers
University
Used 164+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
5 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the shortest path from node A to node F?
A -> B -> D -> F
A -> C -> B -> E -> F
A -> F
A -> C -> E -> F
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Traversal of a graph is different from tree because
DFS of a graph uses stack, but inorrder traversal of a tree is recursive
There can be a loop in graph so we must maintain a visited flag for every vertex
BFS of a graph uses queue, but a time efficient BFS of a tree is recursive.
All of the above
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The Breadth First Search algorithm has been implemented using the queue data structure. One possible order of visiting the nodes of the following graph is
MNOPQR
NQMPOR
QMNPRO
QMNPOR
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Consider the following graph,
Among the following sequences:
(I) a b e g h f
(II) a b f e h g
(III) a b f h g e
(IV) a f g h b e
Which are depth first traversals of the above graph?
I, II and IV only
I and IV only
II, III and IV only
I, III and IV only
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The data structure used for Depth First Algorithm is
STACK
QUEUE
BOTH STACK & QUEUE
NONE OF THESE
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
10 questions
Herencia y Paquetes
Quiz
•
University
10 questions
Parcial 1, Primera serie
Quiz
•
6th Grade - University
10 questions
Choose the level of Bloom’s Taxonomy
Quiz
•
University
10 questions
Semiconductores
Quiz
•
University
10 questions
UX Design
Quiz
•
University
10 questions
Pengantar Coding
Quiz
•
University
10 questions
Metodología XP
Quiz
•
University
10 questions
Serie A 2023
Quiz
•
University
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade