Find all the solutions of the equation 6 See Answer →
Compute the values ( See Answer →
When working modulo See Answer →
Show the comparisons the naive string matcher makes for the pattern See Answer →
Use Dijkstra’s algorithm to find the shortest paths in the graph given in Fig. 3 with See Answer →
Use Kruskal’s algorithm to find a minimal spanning tree in the graph given in Fig. 2.
Show the See Answer →
Determine an LCS of (1, 0, 1, 1, 0, 0, 1, 0, 1) and (0, 0, 1, 0, 1, 1, 0, 1, 0).
See Answer →In the Coin changing problem, we have to give change for n rupees using the least number of coins of a given set of denominations. It is clear that we cannot give change for any See Answer →
Find an optimal parenthesisation of a matrix chain product whose sequence of dimensions is (3, 5, 7, 3, 4).
See Answer →For the following set of points, describe how the closest-pair algorithm finds a closest pair of points
(3, 2), (2, 1), (2, 3), (1, 2), (3, 1), (2, 2), (1, 3), (3, −1), (5, −2)
See Answer →Show how mergesort sorts the array See Answer →
Suppose the Connected-Components is run on the undirected graph See Answer →
Show the results of inserting the keys
Using Fig. 6.3 in page 134 of the book as a model, illustrate the operation of Build-Max-Heap on the array See Answer →
For the set of keys {3, 7, 9, 4, 6, 8, 12} draw binary search trees of height 2, 3, 4, 5 and 6.
See Answer →Using Fig. 7.1 in page 147 of the book as the model, illustrate the operation of Partition on the array See Answer →
With the help of an example, explain the following:
i) Algorithm.
ii) Input and output for an algorithm.
iii) Running time of an algorithm.
Analyse the algorithm and find an upper bound for the run time of the above algorithm.
See Answer →The maximum subsequence sum problem is defined as follows: If See Answer →