Pre-Board examination question paper set for Data Structures and Algorithms from the year 2025.
Tribhuvan University
Faculty of Humanities & Social Sciences
OFFICE OF THE DEAN
2025
Bachelor in Computer Applications
| Paper detail | Value |
|---|---|
| Course | Data Structures and Algorithms |
| Code No. | CACS201 |
| Semester | IIIrd |
| Full marks | 60 |
| Pass marks | 24 |
| Time | 3 hours |
Candidates are required to answer the questions in their own words as far as possible.
Group B
2. Define data structure. Explain the difference between primitive and non-primitive data structures with suitable examples.
3. Define stack. Explain the concept of LIFO with a real-life example.
4. Define a queue. How is it different from a stack? Explain the FIFO principle with a real-life example.
5. What is a graph? Explain the difference between BFS and DFS algorithms with an example.
6. What is a singly linked list? Write the algorithm to delete the first node of a singly linked list and explain it with a diagram.
7. Write the algorithm for the Bubble Sort technique. Sort the following list using Bubble Sort and show the steps: [45,23,11,89,77][45, 23, 11, 89, 77][45,23,11,89,77]
8. Write the in-order, pre-order, and post-order traversals for the following binary tree:
Group C
9. What is a Binary Search Tree (BST)? Write algorithms for insertion and deletion of a node in a BST. Draw the BST after inserting the following keys in order: 50,30,70,20,40,60,8050, 30, 70, 20, 40, 60, 8050,30,70,20,40,60,80. Then delete the node with key 303030 and show the resulting tree.
10. Explain the Divide and Conquer strategy used in Merge Sort. Write the detailed algorithm for Merge Sort and analyze its time complexity. Also, perform Merge Sort on the array: [38,27,43,3,9,82,10][38, 27, 43, 3, 9, 82, 10][38,27,43,3,9,82,10] showing each step clearly.
11. Define graph and tree data structure. Explain breadth first traversal and depth first traversal with example.