You are on page 1of 3

Rajalakshmi Institute of Technology

Department of computer science and engineering


OOPs and DS EC6301
Part B Important Questions
UNIT I
1.
2.
3.
4.
5.
6.
7.

Explain in detail the object oriented programming concepts.


Explain different types of constructors with an example.
What is the purpose of constructor?
What is operator overloading?
Explain function overloading with an example.
Explain the control structures of C++ with suitable examples (for, while, do while).
What is friend function? What is the use of using friend functions in c++? Explain
with a program.
8. What is a structure and explain the members of structure with an
example program
9. Write a program to get the student details and print the same using
pointers to objects and pointers to members of a class. Create a class
student. And use appropriate functions and data members.
10. Explain about Unary Operator and Binary Operator Overloading with
program.
11. Explain the operators used for dynamic memory allocation with
examples

12. Compare and contrast Structured Programming and Object


Oriented Programming.

13. Explain strings.


14. Explain destructor with an example

UNIT II
1. Write a C++ program to explain the concept of inheritance by considering an
example of vehicle.

2.
3.
4.
5.
6.
7.
8.

Explain different types of inheritance with example.


Define overriding with an example program.
What is a virtual function? Explain with example program.
Explain polymorphism with an example.
Narrate type conversion with an example.
Explain protected data with public and private inheritance.
Write a C++ program to implement pure virtual function.

UNIT III

1. Define singly linked list. Explain the various operations of singly linked list with
algorithm.
2. Explain push and pop operations of stack.
3. Explain enqueue and dequeue with example.
4. Write a C ++ program to implement Stack using linked list.
5. Write a C ++ program to implement List ADT.
6. Write a C ++ program to implement Queue using linked list.
7. Convert the expression ((A + B) * C - (D - E) ^ (F + G)) to equivalent Prefix and
postfix notations.
8. Explain the process of conversion from infix expression to postfix using stack.
9. Write a pseudocode for insertion and deletion operations of stack.
10. Write a pseudocode for inserting an element in a linked list.

UNIT IV
1. Discuss the different methods of traversing a binary tree with algorithm.
2. Traverse the tree given below using Inorder, Preorder and Postorder traversals.

3.
4.
5.
6.
7.
8.

Explain breadth first search and depth first search with an example.
Difference between breadth first search and depth first search.
Explain the algorithm for depth first search and breadth first search with the
following graph.
Explain binary search tree with an example.
Write a C++ program to implement binary search tree.
Explain the procedure for deleting the following elements in the tree.
i.
38
ii.
83
iii.
53

UNIT V
1.
2.
3.
4.
5.
6.

Describe divide and conquer technique with the help of merge sort.
Explain the algorithm of Quick sort by sorting the following set of numbers as an
example. 42 47 52 57 62 37 32 27 22
Explain linear search and binary search with example.
Write a C++ program to implement quick sort.
Explain insertion sort with an example.
Sort the following list with merge sort and insertion sort
8, 3, 25, 6, 10, 17, 1, 2, 18, 5

You might also like