MCET-330
CA-3
Data Structure through C (BCAC302)
Full Marks: 25. Time: 1 Hour
Group-A
Answer any five on the following (5X1=5)
1. What is a linked list?
a) A linear data structure with a fixed size
b) A data structure that stores data in a matrix format
c) A collection of elements where each element points to the next element
d) An array with random access capabilities
2. Which of the following is not a type of linked list?
a) Singly linked list
b) Doubly linked list
c) Circular linked list
d) Tree linked list
3. In a singly linked list, the last node's "next" pointer points to:
a) NULL
b) The first node
c) The previous node
d) The last node itself
4. Which type of linked list allows traversal in both directions?
a) Singly linked list
b) Doubly linked list
c) Circular linked list
d) Binary linked list
5. Which operation is not supported in a singly linked list?
a) Insertion at the beginning
b) Insertion at the end
c) Deletion of a specific element
d) Random access of elements
6. Which operation is used to insert a new node after a given node in a linked list?
a) insert_after()
b) add_after()
c) append_after()
d) attach_after()
Group-B
Answer any four on the following (4X5=20)
7. Explain the concept of pointers in C and how they are used in dynamic memory allocation for
data structures like linked lists.
8. Compare and contrast a stack and a queue. Provide real-life examples where each would be
used.
9. Discuss the advantages and disadvantages of using a circular queue over a simple queue.
Implement a circular queue using an array in C.
10. Explain the difference between singly linked lists and circular linked lists. In what scenarios
would a circular linked list be useful?
11. Discuss the difference between linear and non-linear data structures. Provide examples of
each.