GATE CS 2025 (Afternoon) — Question 38

Data StructuresBinary Search Trees (BSTs) & Binary HeapsMCQ2 marks · −2/3 if wrongMedium

A meld operation on two instances of a data structure combines them into one single instance of the same data structure. Consider the following data structures: P: Unsorted doubly linked list with pointers to the head node and tail node of the list. Q: Min-heap implemented using an array. R: Binary Search Tree. Which ONE of the following options gives the worst-case time complexities for meld operation on instances of size n of these data structures?
  1. A
    P: \( \Theta(1) \), Q: \( \Theta(n) \), R: \( \Theta(n) \)
  2. B
    P: \( \Theta(1) \), Q: \( \Theta(n \log n) \), R: \( \Theta(n) \)
  3. C
    P: \( \Theta(n) \), Q: \( \Theta(n \log n) \), R: \( \Theta(n^2) \)
  4. D
    P: \( \Theta(1) \), Q: \( \Theta(n) \), R: \( \Theta(n \log n) \)
Practise the full 2025-AN paper
Challenge a friend: WhatsApp Telegram
From RENYXERAThis week's 10-question challengeSame 10 past-GATE questions for everyone this week — see where you stand.
Practise more on Binary Search Trees (BSTs) & Binary HeapsTimed, in the real exam interface · free to start

A GATE question every morning

One real past-paper question every morning for your branch, answer hidden until you tap. Free on Telegram.

Join
Stuck? Ask in the student group