👁️ 49 views
University of Barishal Logo

University of Barishal

Department of Computer Science and Engineering

2nd Mid Exam

Course Title: Data Structures (CSE-1201)

Semester: 2nd | Session: 23-24

Time: 60 minutes | Marks: N/A

Exam Date: September 17, 2025

1.


1) Explain the difference between linear data structures and non-linear data structures.

Please SUBSCRIBE to view full question

Topics: Linear Data Structure , Non-Linear Data Structure Solution is Coming!
2 Marks
2) Draw a simple diagram of a singly linked list with 5 nodes and indicate the head and tail.

Please SUBSCRIBE to view full question

Topics: Linked List , Singly Linked List Solution is Coming!
3 Marks
3) Consider the array, A = [12, 45, 23, 67, 34]. Perform the following: a) Find the position of 67 using linear search. Show each comparison. [2 Marks] b) Before performing binary search, sort the array in ascending order. Then find the position of 45 using binary search. Show all steps. [3 Marks]

Please SUBSCRIBE to view full question

Topics: Array , Binary Search , Linear Search Solution is Coming!
5 Marks
4) Consider the array, A = [29, 10, 14, 37, 13]. a) Sort the array using Selection sort. Show all passes. [3 Marks] b) Write Pseudocode or algorithm for bubble sort. [2 Marks]

Please SUBSCRIBE to view full question

Topics: Bubble Sort , Selection Sort Solution is Coming!
5 Marks
5) Consider a stack implemented using an array with maximum size 5. Initially, the stack is empty. a) Perform the following operations and show the stack after each step: Push(10), Push(20), Push(30), Pop(), Push(40), Pop(), Push(50) [3 Marks] b) Explain how to handle stack overflow and underflow. Give examples for each case. [2 Marks]

Please SUBSCRIBE to view full question

Topics: Stack Solution is Coming!
5 Marks

Contributors of this Question:

Role Name Date
Uploaded By: F.M.Mustakin Riaz Sept. 17, 2025, 1:38 p.m.
Converted By (Img/PDF to Text): Obaydul Hasan Nayeem Oct. 17, 2025, 12:08 a.m.
Reviewed By: N/A N/A