Professional Documents
Culture Documents
BACHELOR OF COMPUTER
APPLICATIONS (BCA)
Term-End Examination
December, 2020
BCS-042 : INTRODUCTION TO ALGORITHM
DESIGN
Lot-I P. T. O.
[2] BCS-042
P. T. O.
[4] BCS-042
where Wi is a weight.
BCS–042
[2] BCS-042
BACHELOR OF COMPUTER 6x 2 6x 1 O ( x 2 )
Term-End Examination
December, 2021
BCS-042 : INTRODUCTION TO ALGORITHM
DESIGN
P. T. O.
[3] BCS-042 [4] BCS-042
(b) (i) Traverse the following graph using 4. (a) Write a recurrence relation for the
BFS. The starting node is A : 4 following recursive factorial function : 3
P. T. O.
No. of Printed Pages : 3 BCS-042
BCS-042 1 P.T.O.
(d) Apply Kruskal’s algorithm to find out the
minimum cost spanning tree. 6
Starting vertex is A.
BCS-042 2
4. (a) Write a recurrence relation for Fibonacci
series problem. 3
BCS-042 3 P.T.O.
No. of Printed Pages : 4 ?KS-042
Term-End Examination
(W1, W2, W3, W4, W5, W6) = (5, 10, 12, 13, 15, 20)
(b) Write recurrence relation for binary search
algorithm. 3
4. (a) Solve the following recurrence relation: 3
T (n) = 3T (n 12) + n
(b) Find minimum cost spanning tree for the
following graph using Kruskal's algorithm: 7
-x -
No. of Printed Pages : 3 BCS-042
BCS-042 1 P.T.O.
(c) Sort the following list of elements using
‘Insertion Sort’. Also, show intermediate
steps.
28, 6, 29, 90, 5, 42, 80 6
(d) Write the recurrence relation for the best
case of Quicksort algorithm and solve it
using Master method. 6
BCS-042 3 P.T.O.