Skip to content
SmartFigureEduExam kits ₹19

CS25C05 · QP 30038 · Apr/May 2026

CS 25C05 Data Structures using C++ question paper, April/May 2026

Question Paper Code : 30038

B.E./B.Tech. DEGREE EXAMINATIONS, APRIL/MAY 2026.

Second Semester

All Branches

CS 25C05 — DATA STRUCTURES USING C++

(Common to : )

(Regulations 2025)

Time : Three hoursMaximum : 100 marks

Answer ALL questions.

PART A — (10 × 1 + 10 × 3 = 40 marks)

  1. 1.

    Which variable provides an alias name to an existing variable?

    1. (A)Pointer
    2. (B)Static Variable
    3. (C)Reference Variable
    4. (D)Constant Variable

    CO1 · BL1

  2. 2.

    Which keyword is used to allocate memory dynamically in C++?

    1. (A)Malloc
    2. (B)Alloc
    3. (C)New
    4. (D)Create

    CO1 · BL1

  3. 3.

    The class whose members are inherited is called:

    1. (A)Parent class
    2. (B)Base Class
    3. (C)Child class
    4. (D)Both (A) and (B)

    CO2 · BL1

  4. 4.

    Which keyword is used for runtime polymorphism?

    1. (A)Class
    2. (B)Friend
    3. (C)Virtual
    4. (D)Static

    CO2 · BL1

  5. 5.

    The operation of inserting an element into stack is called:

    1. (A)Pop
    2. (B)Push
    3. (C)Insert
    4. (D)Add

    CO3 · BL1

  6. 6.

    Polynomial addition using linked list is efficient because:

    1. (A)Uses recursion only
    2. (B)Dynamic memory allocation
    3. (C)Requires fixed size memory
    4. (D)No memory needed

    CO3 · BL2

  7. 7.

    Right child of node at index i in array representation is:

    1. (A)2i
    2. (B)2i + 1
    3. (C)i + 1
    4. (D)i/2

    CO4 · BL2

  8. 8.

    In a binary tree, each node can have atmost:

    1. (A)1 child
    2. (B)2 children
    3. (C)3 children
    4. (D)Unlimited children

    CO4 · BL1

  9. 9.

    Number of comparisons in worst case of Linear Search for n elements is:

    1. (A)1
    2. (B)log n
    3. (C)n
    4. (D)n²

    CO5 · BL3

  10. 10.

    If an array has 1024 sorted elements, maximum comparisons in Binary Search are :

    1. (A)10
    2. (B)11
    3. (C)512
    4. (D)1024

    CO5 · BL3

  11. 11.

    Differentiate between the constructor and destructor in C++.

    CO1 · BL2

  12. 12.

    How are class members accessed in C++?

    CO1 · BL1

  13. 13.

    Define base class and derived class with an example.

    CO2 · BL2

  14. 14.

    What is a pure virtual function? Give syntax.

    CO2 · BL1

  15. 15.

    Define Omega (Ω) notation with an example.

    CO3 · BL2

  16. 16.

    How can a stack be implemented using linked list?

    CO3 · BL3

  17. 17.

    List the properties of a binary tree.

    CO4 · BL1

  18. 18.

    Differentiate between directed graph and undirected graph.

    CO4 · BL4

  19. 19.

    State the best case and worst-case time complexity of Linear Search.

    CO5 · BL1

  20. 20.

    Which sorting algorithm is suitable for small datasets? Why?

    CO5 · BL5

PART B — (5 × 12 = 60 marks)

  1. 21.
    (a)

    Explain the structures and classes in C++. Compare structures and classes with examples.

    CO1 · BL4

  2. Or
  3. (b)

    Explain function overloading and operator overloading in C++. Write a C++ program to overload any one operator.

    CO1 · BL6

  4. 22.
    (a)

    What are virtual functions? Explain their role in dynamic binding with a suitable example.

    CO2 · BL3

  5. Or
  6. (b)

    Differentiate between composition and inheritance. Explain with real-time examples.

    CO2 · BL4

  7. 23.
    (a)

    Write an algorithm to convert an infix expression into postfix expression. Convert the expression. (A + B) * (C − D) / E

    CO3 · BL6

  8. Or
  9. (b)

    Analyze the time complexity of stack, queue, array access, and linked list insertion operations using Big-Oh notation.

    CO3 · BL4

  10. 24.
    (a)

    Compare adjacency matrix and adjacency list for a graph with 1000 vertices and 1500 edges. Determine which representation is memory efficient and justify with calculations.

    CO4 · BL5

  11. Or
  12. (b)

    Construct a binary tree from the following traversals and perform all traversals again: In order : H D I B E A F C G; Preorder : A B D H I E C F G. Find the height and number of leaf nodes.

    CO4 · BL6

  13. 25.
    (a)

    Write the Merge Sort algorithm and explain the divide and conquer approach with an example.

    CO5 · BL6

  14. Or
  15. (b)

    Explain Heap Sort algorithm with suitable example. Show heap construction and sorting steps.

    CO5 · BL3