MauryaHub PYQ Practice

Programming, Data Structures and Algorithms using Python · End Term · Sep 2022 · AN

Programming, Data Structures and Algorithms using Python · End Term · Sep 2022 AN

← Course papers · Start practice / exam

Questions and published explanations below are available without starting a test. Some questions may not have a published solution yet.

0 / 30 published solutions

Question 219 MCQ · 3.0 marks

Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q219

Question 220 MCQ · 3.0 marks

Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q220

Question 221 MCQ · 3.0 marks

A BFS traversal from a source node s in an unweighted, connected and undirected graph results in a BFS tree T. The tree T is a data structure for computing___
A.
the shortest path between every pair of vertices.
B.
the shortest path from S to only those nodes that are leaves of T.
C.
the shortest path from S to every vertex in the graph.
D.
the longest path from S to every vertex in the graph.

A published solution is not available for this question yet.

Report a correction for Q221

Question 222 MCQ · 3.0 marks

Source diagram or notation
A.
3
B.
4
C.
5
D.
6

A published solution is not available for this question yet.

Report a correction for Q222

Question 223 MCQ · 3.0 marks

Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q223

Question 224 MCQ · 3.0 marks

Which one of the following algorithm design techniques is used in Huffman Encoding algorithm ?
A.
Greedy
B.
Dynamic programming
C.
Divide and conquer
D.
None of these

A published solution is not available for this question yet.

Report a correction for Q224

Question 225 MCQ · 3.0 marks

Let G = (V, E) be an undirected graph having distinct positive edge weights. Let V be partitioned into two non-empty sets X and Y. Let e = (s, t) be the minimum cost edge, with s belonging to X and t belonging to Y. Which of the following statement(s) is/are true? 1. There must be only one unique spanning tree with minimum weight for G. 2. The edge e must definitely belong to minimum cost spanning tree of G
A.
Only 1
B.
Only 2
C.
Both 1 and 2
D.
Neither 1 nor 2

A published solution is not available for this question yet.

Report a correction for Q225

Question 226 MCQ · 3.0 marks

Consider the following binary search tree. The letters indicate the names of the nodes, not the values that are stored.
Source diagram or notation
Which of the following nodes is 3\(^{rd}\) smallest node (in terms of value) in the given binary search tree?
A.
B
B.
I
C.
O
D.
P

A published solution is not available for this question yet.

Report a correction for Q226

Question 227 MCQ · 3.0 marks

The maximum and the minimum number of nodes possible in a binary search tree of height **5** are___. Consider that the height of the empty tree is 0.
A.
32 and 5, respectively
B.
32 and 4, respectively
C.
31 and 5, respectively
D.
31 and 4, respectively

A published solution is not available for this question yet.

Report a correction for Q227

Question 228 MCQ · 3.0 marks

Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q228

Question 229 MCQ · 3.0 marks

Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q229

Question 230 MCQ · 3.0 marks

Source diagram or notation
A.
Only statement 1
B.
Only statement 2
C.
Only statement 3
D.
Statement 2 and Statement 3
E.
Statement 1 and Statement 2

A published solution is not available for this question yet.

Report a correction for Q230

Question 231 MCQ · 4.0 marks

Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q231

Question 232 MCQ · 4.0 marks

Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q232

Question 233 MCQ · 4.0 marks

Source diagram or notation
A.
1
B.
2
C.
3
D.
4

A published solution is not available for this question yet.

Report a correction for Q233

Question 234 MCQ · 4.0 marks

Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q234

Question 235 MCQ · 4.0 marks

Which of the following options represents the fail function (or prefix function) for pattern **'ABABAABA'** in the Knuth-Morris-Pratt (KMP) algorithm?
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q235

Question 236 MSQ · 3.0 marks

Source diagram or notation
A.
44
B.
12
C.
55
D.
101
E.
112

A published solution is not available for this question yet.

Report a correction for Q236

Question 237 MSQ · 3.0 marks

Which of the following statements is/are true about adjacency list representation and adjacency matrix representation of a graph?
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q237

Question 238 MSQ · 3.0 marks

Which of the following statements is **true** about Dijkstra's algorithm to find the shortest path?
A.
The shortest path returned by Dijkstra's algorithm always passes through the least number of vertices.
B.
To decide which node to visit next, Dijkstra's algorithm selects the node with smallest known distance.
C.
Dijkstra’s algorithm may fail for graphs with negative weights because it does not reconsider a node once it marks it as visited even if a shorter path exists than the previous one.
D.
It returns the shortest path between all pairs of nodes.

A published solution is not available for this question yet.

Report a correction for Q238

Question 239 MSQ · 3.0 marks

Which of the following is/are **true** about AVL Tree? Assume that the height of the empty tree is 0.
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q239

Question 240 MSQ · 3.0 marks

Which of the following statements is/are **true** about Huffman coding algorithm?
A.
In an optimal Huffman tree, if leaf labelled **x** is at depth smaller than leaf labelled **y**, then **frequency(x) >= frequency(y)**
B.
In an optimal Huffman tree, if leaf labelled **x** is at depth smaller than leaf labelled **y**, then **frequency(x) <= frequency(y)**
C.
Huffman coding algorithm always generates prefix code.
D.
Huffman coding algorithm is based on a greedy approach.

A published solution is not available for this question yet.

Report a correction for Q240

Question 241 NAT · 4.0 marks

Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q241

Question 242 NAT · 4.0 marks

Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q242

Question 243 NAT · 4.0 marks

Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q243

Question 244 NAT · 4.0 marks

Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q244

Question 245 NAT · 3.0 marks

Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q245

Question 246 MSQ · 4.0 marks

Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation
E.Source diagram or notation
F.Source diagram or notation

A published solution is not available for this question yet.

Report a correction for Q246

Question 247 MCQ · 3.0 marks

Source diagram or notation
Based on the above data, answer the given subquestions.
Source diagram or notation
A.
A greedy algorithm
B.
A dynamic programming algorithm
C.
A divide and conquer algorithm
D.
None of these

A published solution is not available for this question yet.

Report a correction for Q247

Question 248 MCQ · 3.0 marks

Source diagram or notation
Based on the above data, answer the given subquestions.
Source diagram or notation
A.Source diagram or notation
B.Source diagram or notation
C.Source diagram or notation
D.Source diagram or notation
      **DBMS** **Section Id :** 64065329425 **Section Number :** 9 **Section type :** Online **Mandatory or Optional :** Mandatory **Number of Questions :** 25 **Number of Questions to be attempted :** 25 **Section Marks :** 50 **Display Number Panel :** Yes

A published solution is not available for this question yet.

Report a correction for Q248