TOTSOL - Total Solution: Exam Conducted by
TOTSOL - Total Solution: Exam Conducted by
TOTSOL - Total Solution: Exam Conducted by
Visit : www.totsolindia.com
Question No : TOTSOL-DSTR-02
Subject : Data Structure
Full Marks : 100
Time : 1. 5 hrs.
Answer all questions. Each question carries 2 marks. 0.5 marks will be deducted as -ve mark per wrong answer. Use ORS.
C> n-2
D> n-1
4. A simple graph in which there exists an edge between every pair of vertices is called
A> Pirated graph
C> Complete path
B> Hamiltonian graph
D> Complete graph
5. In a complete graph with n vertices, there are (n-1)/2 edge disjoint Hamiltonian circuits if n is an
odd number >=
A> 2
B> 3
C> 4
D> 1
6. A sufficient condition for a simple graph G to have a Hamiltonian Circuit is that the degree of
every vertex in G be atleast
A> n/2
B> n/3
C> n/4
D> n/6
7. If in a graph G there is one and only one path between every pair of vertices then G is a
A> Path
C> Tree
B> Walk
D> Circuit
8. Which of the following is false :
A> A tree has n vertices has n-1 edges.
B> Any connected graph with n vertices and n-1 edges is a tree
C> A graph is a tree if and only if it is minimally connected.
D> All of the above are false
9. Which of the following are not true for tree in a graph G :
A> G is connected and is circuitless
C> G is circuitless and has n-1 edges
B> G is connected and has n-1 edges
D> G is maximally connected graph.
10. The distance between vertices of a connected graph is a
A> Unity
B> Two walks
C> Metric
D> Tirtiary
11. A tree in which one vertex (called the root) is distinguished from all the others is called
A> Binary tree
C> Path
B> Rooted tree
D> Walk
visit : www.totsolindia.com
Q. No : TOTSOL-DSTR-02
C> n2
D> n3
13. A graph that cannot be drawn on a plane without crossover between edges is called
A> Planner
C> Path
B> Non-planner
D> Walk
14. The ring sum of two circuits in a graph G is either a circuit or an edge disjoint union of
A> Paths
C> Graphs
B> Walks
D> Circuits
15. A set of vectors X1, X2, X3, Xr if for scalars C1, C2, C3,.Cr in F the expression
C1X1+C2X2+C3X3+.CrXr =0 is called
A> Linearly factor
C> Linearly independent
B> Linearly dependent
D> None of the above
16. Which of the following statement is not valid ?
A> A graph has a dual if and only if it is planer
B> An edge incident on a pendant vertex is called a pendant edge
C> The reduced incidence matrix of a tree is singular
D> The number of vertices of odd degree in a graph is always even.
17. A Planer graph may be embedded in a plane such that any specified region can be made the
A> Finite zone
C> Infinite region
B> Finite region
D> At edge
18. The number of linearly independent vectors required to span the subspace is called
A> Subspace
C> Metric space
B> Space
D> Dim. of subspace
19. In a special array, a large proportion of the elements are zero, but those which are non-zero
randomly distributed. This defines the
A> Arrays
C> Vectors
B> Sparse arrays
D> Matrices
20. A tree with N nodes has
A> N edges
B> N2 edges
21. A binary tree with N internal nodes has maximum of external nodes
A> N
B> N+2
C> N+3
22. The height of a full binary tree with N internal nodes is about
A> Log2N
B> N Log N
C> Log N
D> N+1
D> 2N
23. Choose the right statement(s) regarding the BST(binary search tree)
i> Each data value in its left subtree less than the root value
ii> Each data value in its right subtree greater than the root value
Copy right TOTSOL-Total Solution
visit : www.totsolindia.com
Q. No : TOTSOL-DSTR-02
iii> Left and right subtree are again binary search trees
iv> It is an ordered binary tree
A> I and II are correct
B> I, II, III are correct
visit : www.totsolindia.com
Q. No : TOTSOL-DSTR-02
A> B-tree
B> BST
visit : www.totsolindia.com
Q. No : TOTSOL-DSTR-02
43. If one uses straight two-way merge sort algorithm to sort the following elements in ascending
order
20, 47, 15, 8, 9, 4, 40, 30, 12, 17
then the order of these elements after the second pass of the algorithm is
A> 8, 9, 15, 20, 47, 4, 12, 17, 30, 40
C> 15, 20, 47, 4, 8, 9, 12, 30, 40, 17
B> 8, 15, 20, 47, 4, 9, 30, 40, 12, 17
D> 4, 8, 15, 20, 47, 12, 17, 30, 40, 9
44. Which of the following is correct?
A> B-trees are for storing data on the disk and B+ trees are for main memory
B> Range queries are faster on B+ trees
C> B-trees for primary indexes and B+ trees for secondary indexes
D> B+ tree contains all records at its leaf nodes which is not true for B-tree
E> None of the above
45. Which of the following addressing modes permits relocation without any change what so ever in
the code
A> Indirect addressing
C> Base register Addressing
B> Indexed addressing
D> PC relative Addressing
46. Which one of the following algorithm design techniques is used in finding all pairs of shortest
distances in a graph
A> Dynamic Programming
C> Greedy
B> Back Tracking
D> Diode and conquer
47. Give the correct matching for the following pairs :
(a) O(log n)
(P) Selection
(b) O(n)
(Q) Insertion Sort
(c) O(n log n)
(R) Binary Search
(d) O(n2)
(S) Merge Sort
A> a-R, b-P, c-Q, d-S
B> a-R, b-P, c-S, d-Q
48. How many sub-strings of different lengths (non-zero) can be formed from a character string of
length n ?
A> n
B> n2
C> 2n
D> n(n+1)/2
49. Which of the following statements is false?
A> A tree with n nodes has (n-1) edges
B> A labeled rooted binary tree can be uniquely constructed given its post-order and preorder transversal result
C> A complete binary tree with one internal nodes has (n+1) leaves
D> The maximum of nodes in a binary tree of height h is (2h+1-1)
50. A function can
A> Perform a task
B> Return a value
C> Change value of actual arguments,
in call by reference
visit : www.totsolindia.com
Q. No : TOTSOL-DSTR-02
B
B
D
C
B
6. A
7. C
8. D
9. A
10. C
11. B
12. B
13. B
14. D
15. C
16. C
17. C
18. D
19. B
20. C
21. D
22. A
23. C
24. B
25. A
26. B
27. A
28. B
29. D
30. D
31. C
32. D
33. A
34. A
35. C
36. A
37. D
38. B
39. A
40. C
41. C
42. D
43. B
44. D
45. C
46. A
47. B
48. A
49. C
50. D
Hints 28.
Given array is Array(col, row)=Array(20:50,20:40) and find location for Array(32:26)
(col-colmin)*(rowmax-rowmin+1)+row = (32-20)*(40-20+1)+(26-20) = 258
Hints 36.
Given array is Array(col, row)=Array(50:100,50:75) and find location for Array(62:56)
(col-colmin)*(rowmax-rowmin+1)+row = (56-50)*(100-50+1)+(62-50) = 318
visit : www.totsolindia.com
Q. No : TOTSOL-DSTR-02