All mock tests are FREE till 31 December — register to save your progress
UGC NET · PAPER 2

UGC NET Paper 2 Computer Science – Unit 7: Data Structures and Algorithms PYQ (December 2023)

7 questions · answer key at the end · updated 11 Oct 2026
Q2. Which of the following is NOT a palindromic subsequence of the string "ababcdabba"?
  1. abcba
  2. abba
  3. abbbba
  4. adba
Answer & explanation →
Q3. Which of the following is TRUE?
  1. The cost of searching an AVL tree is Θ(log n) but that of a binary search tree is O(n)
  2. The cost of searching an AVL tree is Θ(log n) but that of a complete binary tree is Θ(n log n)
  3. The cost of searching a binary tree is O(log n) but that of an AVL tree is Θ(n)
  4. The cost of searching an AVL tree is Θ(n log n) but that of a binary search tree is O(n)
Answer & explanation →
Q4. What is the result of evaluating the postfix expression "4 3 * 2 5 * + 8 -"?
  1. 8
  2. 14
  3. 10
  4. 5
Answer & explanation →
Q25. Which data structure is typically used to implement a hash table?
  1. Linked list
  2. Array
  3. Binary tree
  4. Stack
Answer & explanation →
Q26. Which collision resolution technique involves maintaining a linked list of collided keys?
  1. Linear probing
  2. Quadratic probing
  3. Chaining
  4. Double hashing
Answer & explanation →
Q27. Consider the following functions: f(n) = 3n√n, g(n) = 2√n log₂ n, h(n) = n!. Which of the following is true?
  1. h(n) is O(f(n))
  2. h(n) is O(g(n))
  3. g(n) is not O(f(n))
  4. f(n) is O(g(n))
Answer & explanation →
Q28. 2-3-4 trees are B-trees of order 4. They are isometric to ______ trees.
  1. AVL
  2. AA
  3. 2-3
  4. Red-Black
Answer & explanation →

Answer key

  1. 2 – D
  2. 3 – A
  3. 4 – B
  4. 25 – B
  5. 26 – C
  6. 27 – D
  7. 28 – D