Professional Documents
Culture Documents
Edges of a directed graph are drawn with an arrow from the Tail to Head
In which of the following path all the vertices except first and last are distinct Simple Path
Which of the following are the most commonly used matrix representation of Graph? Adjacency
Matrix
Which of the following is a 2-dimensional array of size n X n where n is the number of vertices
in the graph? Adjacency Matrix
For which of the following the Adjacency Matrix is Symmetric Undirected Graph
The space needed to represent a graph using its adjacency matrix is ____N2_______ locations
where N is the number of vertices in the graph.
In undirected graph any edge is represented by the pair Ans: (V1, V2)
In directed graph any edge is represented by the pair Ans: <V1, V2>
The path in which first and last vertices are same is called Cyclic Path
The adjacency lists representation of an undirected graph, each edge (Vi, Vj) is represented by
___2____ entries
In a graph, represented with adjacency matrix the digonal elements are non zero for
graph having loops
The number of non zero entries in an adjacency matrix are equal to number of edges
A graph in which all nodes are of equal degrees is known as: ANs: regular graph
The minimum number of edges in a connected cyclic graph on ‘n’ vertices is…....
If G is an directed graph with 20 vertices, how many boolean values will be needed to represent
G using an adjacency matrix? Ans: 400
Which of the following edges represent the same path if a1 and a2 are the two vertices of an
undirected graph ? Ans: (a1, a2) and (a2, a1)
The n rows of the adjacency matrix are represented as __n_ linked list.
What will be produced by Depth First Traversal for an undirected graph which is not connected?
Forest
Select the correct option for the following I. Depth first search visits the starting
vertext twice. II. Breadth first search visits each node just one time Ans: FALSE, TRUE
Traversal of a graph is different from tree because There can be a loop in graph so we must
maintain a visited flag for every vertex
What will be produced by Depth First Traversal for a connected undirected graph Ans:Spanning
Tree
What will be produced by Depth First Traversal for a connected directed graph Ans: Forest
Which of the following data structure is used for breadth first traversal of graph queue
Which of the following data structure is used for depth first traversal of graph stack
Breadth first search is method of ----all successors of visited node before any successors of any
of those successors
A. BFS 1. Heap
B. DFS 2. Queue
The time complexity of DFS algorithm which when implemented using adjacency matrix is -----
O ( |V|2 )
The time complexity of DFS algorithm which when implemented using adjacency list is -----
O ( |V| + | E | )
The time complexity of BFS algorithm which when implemented using adjacency matrix is -----
O ( |V|2 )
The time complexity of BFS algorithm which when implemented using adjacency list is -----
O ( |V| + | E | )
In the Depth First traversal we process all of a vertex’s descendents before we move to an
adjacent vertex
The spanning tree resulting from a call to depth first tree is called: Ans: depth first spanning tree
The spanning tree resulting from a call to breadth first tree is called breadth first spanning tree
The minimum cost of a spanning tree is given by sum of costs of the edges that are inserted
while building the spanning tree of minimum cost
Which of the following is not a part of node structure of an adjacency multilist for a digraph?
previous link to edge
Which of the following algorithm gives the shortest path between two nodes Ans: Dijkstra's
algorithm
What algorithm technique is used in the implementation of Kruskal solution for the MST?
Ans: greedy technique
which of the following algorithm forms forest while creating minimum spanning tree for graph
Ans: Kruskal's
If graph is dense graph then which algorithm will work better for finding minimum cost
spanning tree? Ans: Prim's
If graph is sparce graph then which algorithm will work better for finding minimum cost
spanning tree? Ans: Kruskal's
Graph can have more than one number of spanning trees True
Graph can have more than one number of minimum spanning trees: True
if e are no of edges in graph and n are no of vertices then Kruskal's algorithm is having time
complexity __O(e log n)_____
____
In the minimal-spanning tree technique, if two or more nodes are equally near, this suggests that
there may be multiple solutions.
While calculating the shortest path between two nodes in the adjacency matrix the path that does
not exist between two nodes is taken as infinity
Insertion of any edge to a spanning tree form a unique cycle because for any pair of vertices
there exists only one paths between them
Which of the following paths contains all vertices in the graph? hamilton path
____