CD3281 Set2
CD3281 Set2
(Regulations 2021)
1. a. Write a Python code to implement LIFO structure. Use Linked List Implementation.
Write a Python code to implement the operations of binary search tree and perform the following
3. A person wants to visit several locations of the city. He starts from a vertex and then wants to
visit every place connected to this vertex and so on. What traversal methodology suits best for
him and implement it using Python?
4. a.) Code a Python program for the implementation of priority queue using the following heap
operations using Minheap.
b.) Write a Python program to sort the following numbers using Quick sort:
Page 1 of 3
5. a. Write a Python program for evaluation of postfix expression
7. Create a Python class for List ADT and create the routine for following operations: insert, delete,
count, reverse, search, find kth element. Use Linked List implementation.
8. Write a Python Program to create a binary tree and obtain the order of the nodes by applying
various tree traversal methods.
9. a. Write a Python to implement Dijikstra’s algorithm to solve the single source shortest path
problem.
b. Input an adjacency matrix of a graph and find the indegree and outdegree of each
node in the graph.
10. Implement any one open and closed hashing tables using Python.
11. a. Write a Python program to sort the elements using Merge sort.
b. Write a Python Program to convert the infix expression a+ (b*c-d)/e into postfix expression.
12. Code a Python program to implement List ADT by using array and linked list for the following
operations
i.) Create ii.) Traverse iii.) Find. iv.) Delete v) Reverse
13. Write a Python code to implement the hashing with hash table of size 10 using separate Chaining
for the following numbers 17,22,11,12,45,27,33,44
Page 2 of 3
14. Write a Python program to perform the following operations on binary search tree
15. Write a Python program to find minimum spanning tree using Prim’s Algorithm
16. Write a Python program for implementing a Queue ADT using linked list.
17. a. Implement the priority queue using binary heap property. Use the two categories of binary
heap for implementation.
b. Write a Python program to search the element in a list by using the searching method in divide
and conquer Technique.
19. a. Code a Python program for the implementation of priority queue using the following heap
operations using Maxheap i.) Insert ii.) Delete
b. Write a Python code to implement the hashing with hash table of size 10 using Separate
Chaining for the following numbers 17,12,41,61,75,2,5,8
20. a.) Implement the DFS to perform depth first search on the graph using Python.
b.) Code a Python program to implement the hashing with hash table of size 10 using open
addressing for the following numbers 6,3,63,18,4,5,12, 8, 33.
Page 3 of 3