This document outlines the units and topics covered in a course on Design and Analysis of Algorithms. It includes definitions of key algorithm concepts like time complexity, asymptotic notation, and algorithm design approaches. Data structures like arrays, binary search trees, AVL trees, and red-black trees are discussed. Specific algorithms like quicksort, dynamic programming, greedy algorithms, and minimum spanning trees are covered. The document also introduces computational complexity classes like P, NP, NP-complete and NP-hard and some famous unsolved problems in computer science.
MARUTI SUZUKI- A Successful Joint Venture in India.pptx
Daa tutorial
1. Uttaranchal University
Tutorial
Course: MCA-III
Subject: Design and Analysis of Algorithm (MCA 3.2)
Unit-I
1. What are algorithms? Why do we study algorithms?
2. What is the main difference between algorithms and programs?
3. Define main characteristics of an algorithm
4. Define different design approaches of an algorithm
5. How do you calculate running time of an algorithm?
6. What is time-space complexity of an algorithm?
7. Write pseudo code for an algorithm that adds the elements of an array of integers.
8. Write pseudo code for an algorithm that finds the largest element of an array of integers
9. Define order of growth of a function
10. Define Big oh notation
11. What is the use of asymptotic notation?
12. What is recurrence? Define substitution method
13. What is the running time of quick sort when all the elements of array A have the same value?
14. Define Theta notation.
15. Define Omega notation
16. Define little Oh and Little Omega notation.
Unit-II
1. Why is a binary search tree an efficient way to store and retrieve data?
2. What are the differences between an AVL tree and a Binary tree? When would you use and AVL
Tree?
3. Show how an AVL tree can be colored as a red-black tree?
4. Draw the red-black tree resulting from inserting the numbers 5,16,22,45,2,10,18,30,50,12,1 in
this order
5. A sub tree of a red-black tree is red-black. Right or wrong? If wrong , provide counter example
6. Draw a red-black that is not an AVL tree
7. After a removal in RB tree,what is the maximum number of rotations required to rebalance the
tree?
2. 8. After an addition in a red-black tree, what is the maximum number of rotations required to
rebalance the tree?
Unit-III
1. What is dynamic programming? Give its various applications.
2. Differentiate between divide and conquer and dynamic programming.
3. Find an optimal parenthesization of a matrix chain product whose sequence of dimensions is
< 5,10,3,12,5,50,6>
4. Write the control abstraction for greedy method.
5. What are the constraints of knapsack problem?
6. Define feasible and optimal solution.
7. 0/1 knapsack issue cannot be solved by Greedy technique. Why?
8. Explain briefly about traveling sales person issue.
Unit-IV
1. What is a minimum cost spanning tree?
2. What do you mean by multistage graph?
3. Specify the algorithms used for constructing Minimum cost spanning tree.
4. State single source shortest path algorithm (Dijkstra’s algorithm).
5. Solve the knapsack issue using greedy technique.
6. Explain Prim’s algorithm to construct Minimum cost spanning tree.
7. Explain Kruskal’s algorithm to construct Minimum cost spanning tree.
8. Define Breadth First search.
9. Define Depth first search.
Unit-V
1. What are P and NP?
2. What is deterministic algorithm?
3. What is Non-Deterministic Algorithm?
4. Draw the relationship ranging from P, NP,NP complete and NP-hard.
5. What is the property of NP-Complete problem?
6. What is the property of NP-Hard problem?
7. What are the two most famous unsolved issues in Computer science?
8. Explain the basic concepts of P,NP,NP-Complete and NP-Hard.