DAA Course File
DAA Course File
MOHALI
Vision
Building the nation and the society through providing total, integrated and trans-cultural quality education and
to be the global front runner in value education and nurturing talent in which Modernity Blends with
Tradition.
Mission
To provide education at all levels in all disciplines of modern times and in the futuristic and emerging frontier
areas of knowledge, learning and research and to develop the overall personality of students by making them
not only excellent professionals but also good individuals, with understanding and regard for human values,
pride in their heritage and culture, a sense of right and wrong and yearning for perfection and imbibe attributes
of courage of conviction and action.
2. Vision, Mission of Amity School of Engineering and Technology Department
Vision
To nurture talent and create globally acceptable, cognitively thinking industry ready technocrats with ethics
and compassion towards socio-economic growth of the society.
Mission
To execute industry-oriented curriculum with an experiential learning pedagogy inculcating social and
ethical values.
Undergraduate and Post Graduate programs that integrate foreign languages, communication skills,
team building, interdisciplinary approach and tailored curriculum.
Inculcate research oriented approach amongst students through mentorship and provide world class
facilities
3. Program statements i.e., PEOs, PO(s), PSOs
Programme Outcomes (POs)
At the end of the program, students will be able to
Course Learning Outcomes: After studying this course students will be able to:
1. For a given algorithms analyze worst-case running times of algorithms based on asymptotic
analysis and justify the correctness of algorithms.
2. Explain when an algorithmic design situation calls for which design paradigm (greedy/
divide and conquer/backtrack etc.).
3. Explain model for a given engineering problem, using tree or graph, and write the
corresponding algorithm to solve the problems.
4. Demonstrate the ways to analyze approximation/randomized algorithms (expected running
time, probability of error); &
5. Examine the necessity for NP class-based problems and explain the use of heuristic
techniques.
CO PO Mapping
Mapping of syllabus with Course Outcomes:
Theory Examination
WEIGHTAGE 16 4 5 25 25 25
(%)
Practical examination
Continuous Assessment/Internal
End Term Examination
Assessment
Lab Record
including
Minor Major
Components Attendance, Viva-
Experiment/ Experiment Viva Total
(Drop down) Ethics, voce
Spotting (Practical)
Precautions,
Interactions
Weight age
20 15 15 35 15 100
(%)
80-84 0.5
85-89 1
90-94 1.5
95-100 2
8. Assessment tools/criteria (direct and indirect)
S. No Assessment tools/criteria (direct and indirect) Average Marks
1 Mid-Term Exam 25
2 Continuous Assessment (Quiz, assignments, Term Paper) 25
3 Student Teacher interaction 00
4 End semester exam (Offline written exam) 25
5 Online MCQ AUP Exam 25
9. Lecture/Course Plan (Sample)
Session plan is uploaded on the amizone portal
10. Class, Lab & Faculty Time table
Class time table
B
.
T
e3
cr
hd
( S
Ce
Sm
Ee
) s
t
2e
2r
B D 91 11 1 1 11
. A 0 3 4
T Y : : :
e 1 1 1
c 5 5 5
h - - -
1 1 1
C 1 4 5
S : : :
E 1 1 1
0 0 0
(
B
)
D
B u
d
it
S
L
a
R o
u
c
E
b r
s
( e
G s
A
M
3 /
o
) M
n D
/ O
d P DO T
K
I O
a
T C
y
/
L C
a la
b s
s
(
a
G
c
4
ti
)
vi
t
y
T I O DC A A
u T u u
e d d
s L it it
d a c c
a b o o
u u
r r
s s
( e e
G s s
3 / /
) M M
/ O O
D O O
S C C
y / /
L C C
a la la
b s s
s s
( a a
G c c
4 ti ti
) vi vi
t t
y y
W O PC DP D
e S O y S
d A t L
n h a
e o b
s n (
d P G
a r 3
y o )/
g. P
y
t
h
o
n
L
a
b
(
G
4
)
O
R
S
e
L s
a e
b a
r
( c
T
G h
h Li
3 L
u b
) e
r r
/ c
s P DP a
D t
d r
S u
a y
r
y L e
a /
b S
p
(
o
G
rt
4
s
)
F P PC DA P
r y O u y
i t A d t
d h it h
c
o
u
o
r
n
s
L
e
a
s
b
/
o (
M
n G
O
3
O
a P )/
C
y r O
/
o S
C
g L
la
. a
s
b
s
(
a
G
c
4
ti
)
vi
t
y
11.Lecture/Unitwise class notes with indexing (1 unit)
12. Question bank (AUP Exam)
As the mode of teaching – learning process is online, following strategies were followed:
Section A (4x4=16)
1. What do you mean by greedy method in DAA? You have a knapsack with a maximum weight
capacity of 15 units. You are given the following items with their weights (W_i) and values (V_i):
1 2 10
2 3 5
3 5 15
4 7 7
5 1 6
Find the combination of items to maximize the total value in the knapsack without exceeding its
weight capacity.
2. Solve the equation to determine complexity using Master’s theorem:
T (n) = 6T (n/3) + n2 log n
Explain closure properties on Asymptotic notation.
3. Explain spanning tree. Consider a complete undirected graph with vertex set {0, 1, 2, 3, 4}. Entry Wij
in the matrix W below is the weight of the edge {i, j}. What is the minimum possible weight of a
spanning tree T in this graph such that vertex 0 is a leaf node in the tree T?
NOTE: You can use any method to find MST.
4. A file contains the following characters with the frequencies as shown. If Huffman Coding is used for
data compression, determine-
A 10
E 15
I 12
O 3
U 4
S 13
T 1
Section B
1. Explain Dijkstra’s algorithm in detail. Why it is used? Solve the following question using Dijkstra’s
algorithm: Using Dijkstra’s Algorithm, find the shortest distance from source vertex ‘S’ to remaining
vertices in the following graph-
(9)
7. CO wise Assignments/ Quizzes – (Include Quizzes and Assignment Questions)
Test:
1. Which of the following notations represents the upper bound of an algorithm's running time?
A) Big O notation
B) Theta notation
C) Omega notation
D) Little o notation
3. If an algorithm has a worst-case time complexity of O(n^2) and a best-case time complexity of O(n log n),
which notation provides a tighter bound for the algorithm's time complexity?
A) Big O notation
B) Theta notation
C) Omega notation
D) Little o notation
4. Which of the following best describes the key principle of greedy algorithms?
A) Making decisions based on local optimization without considering their global effects.
B) Exploring all possible solutions exhaustively to find the best one.
C) Solving problems using a recursive divide-and-conquer approach.
D) Analyzing problems using dynamic programming techniques.
5. Which of the following problems can be efficiently solved using Huffman coding, a greedy algorithm?
6. In the fractional knapsack problem, the greedy strategy is to select items based on their:
A) Value-to-weight ratio.
B) Total value.
C) Total weight.
D) Total profit.
7. Which of the following statements is true about the greedy approach in the fractional knapsack problem?
Test:
1. What is the primary goal of a Minimum Spanning Tree (MST) algorithm in a weighted graph?
2. Which of the following greedy algorithms is commonly used to find a Minimum Spanning Tree
(MST)?
A) Quick Sort
B) Dijkstra's Algorithm
C) Kruskal's Algorithm
D) Breadth-First Search (BFS)
3. What data structure is commonly used in Prim's algorithm to efficiently select the next edge to
include in the MST?
4. In a connected graph with N vertices, how many edges does a Minimum Spanning Tree (MST)
typically have?
A) N
B) N - 1
C) N^2
D) 2N
A) The distance between the source vertex and the current vertex.
B) The distance between the source vertex and the target vertex.
C) The sum of edge weights along the current path.
D) The maximum edge weight in the graph.
8. The Master Theorem provides a method for analyzing the time complexity of algorithms that can
be expressed in the form of a recurrence relation of the following type:
Test:
1. In the context of transitive closure, what does the entryT[i][j] represent in the Floyd-Warshall
dynamic programming table?
a. The weight of the edge between vertices i and j.
b. The reachability between vertices i and j.
c. The number of edges in the shortest path from i to j.
d. The maximum flow from i to j.
2. In BFS, which data structure is typically used to keep track of the vertices to be visited?
a. Stack.
b. Queue
c. Priority queue
d. Hash table
3. What does the entry D[i][j] represent in the Floyd-Warshall dynamic programming table?
a. The weight of the edge between vertices i and j
b. The shortest path distance from vertex i to vertex j
c. The number of edges in the shortest path from i to j
d. The maximum flow from i to j
4. Which algorithm is commonly used to solve the All-Pairs Shortest Path problem for dense graphs?
a. Dijkstra's algorithm
b. Bellman-Ford algorithm
c. Floyd-Warshall algorithm
d. Prim's algorithm
5. In Bellman-Ford algorithm, how many iterations are required to find the shortest paths in a graph
with V vertices?
a. V - 1
b. V
c. V + 1
d. log(V)
6. In DFS, when do you backtrack?
a. When a cycle is detected.
b. When the destination vertex is encountered.
c. When the stack becomes empty.
d. When all vertices have been explored.
7. What is the role of the visited array in DFS?
a. To store the values of visited vertices.
b. To mark vertices that have been added to the stack.
c. To store the shortest path between vertices.
d. To store the adjacency matrix.
8. In BFS, when do you stop the traversal process?
a. When all vertices have been added to the queue.
b. When the destination vertex is encountered.
c. When the queue becomes empty.
d. When a cycle is detected.
8. Record of Evaluated answer sheet (Mark Rubrics) – Mid Term, CAS, Total
File is uploaded for the reference
9. Lab manual (with Solutions)
File has been uploaded for the reference
10. Guidelines regarding labwork
General Guidelines For The Students
A Student is expected to maintain the decorum of the laboratory by maintaining proper discipline.
Student is expected to be punctual in lab, should keenly perform the experiment allotted to him without
moving from one lab to another and even experimental set up should not be left until it unavoidable.
Mobile phones are not allowed in the labs and should be kept in the bags in silent or switch-off mode.
Keep the work area clear of all materials except those needed for your work. Extra books, purses, bags
etc. should be kept in the racks placed in the laboratories.
Clean up your work area before leaving.
Eating and drinking is not allowed in the lab.
11.Criteria for Evaluation of slow/fast learners
MST marks
Quizzes
Vivas
Faculty Student interaction
12.Students list/List of slow learners/ list of fast learners – 5 students getting
higher marks or less than 50%
List of students
1. A25304821002 Bhumika
2. A25304821008 Raman
1. A25304821004 Jashan
2. A25304821006 Kuber
13.Actions taken to improve performance of slow learners; ; impact of actions
taken
3-5 Extra classes were provided to students getting attendance less than 75% so that he/she would cover
the syllabus and not debarred from final examinations.