[go: up one dir, main page]

0% found this document useful (0 votes)
96 views5 pages

Dsa QB

This document contains question banks for the Descriptive Data Structures and Algorithms subject for the second year Computer Science Engineering students. It includes short answer questions and long answer questions for each of the 5 units - Introduction and Overview & Linked List, Stacks & Queues, Trees, Graphs & Searching, and Sorting. For each unit, there are 10 short answer questions carrying 2 marks each and 5-10 long answer questions carrying 10 marks each. The questions cover key concepts, properties, representations, operations, algorithms and examples for different data structures.

Uploaded by

jayapriya kce
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
96 views5 pages

Dsa QB

This document contains question banks for the Descriptive Data Structures and Algorithms subject for the second year Computer Science Engineering students. It includes short answer questions and long answer questions for each of the 5 units - Introduction and Overview & Linked List, Stacks & Queues, Trees, Graphs & Searching, and Sorting. For each unit, there are 10 short answer questions carrying 2 marks each and 5-10 long answer questions carrying 10 marks each. The questions cover key concepts, properties, representations, operations, algorithms and examples for different data structures.

Uploaded by

jayapriya kce
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

SIDDHARTH GROUP OF INSTITUTIONS:: PUTTUR

Siddharth Nagar, Narayanavanam Road – 517583

QUESTION BANK (DESCRIPTIVE)

Subject with Code : DSA(18CS0504) Course & Branch: B.Tech – CSE


Year & Sem: II-B.Tech & I-Sem Regulation: R18

UNIT – I: Introduction and Overview & Linked List

Short Answer Questions [2Marks]

1. Define data structure. Mention any two applications of data structures?


2. What is a double linked list? Name the three fields of double linked list?
3. List out the applications of a linked list?
4. What is a double linked list? Name the three fields of double linked list.
5. State the difference between stacks and linked lists?
6. Define and differ data and information
7. Define entity and entity set, domain.
8. Explain different types of data structures
9. List the advantages of linked lists over arrays.
10. Differentiate singly linked list and doubly linked list.
Long Answer Questions [10 Marks]
1. Write an algorithm to perform the following operations on a single linked list.
(i) Insert new node at the beginning of list. (ii) Count the number of nodes.
2. What is a double linked list? Name the three fields of double linked list?
3. What is the difference between the single linked list and double linked list, circular linked list?
4. a)What is array? Explain different types of arrays.
b) Explain about array operations?
5. Explain the applications of linked lists.
6. Explain about single linked list?
7. a) What is the difference between the arrays and linked list?
b) What are the advantages and disadvantages of circular linked list?
8. Explain briefly about various types of linked lists with suitable examples.
9. Explain how to create circular linked list and insert nodes at end.
10. Explain the following operations in a doubly linked list:
(a) Create an empty list. (b) Insert the elements 10 and 20 at the front of the list.
(c) Insert the elements 30 at the middle of the list.
(d) Insert the elements 15, 45 at the end of the list.
(e) Delete the middle element from the list.
.

UNIT – II: Stacks & Queues

Short Answer Questions [2Marks]


1. Define a Stack?
2. List out the applications of stack and Queue?
3. Define Queue? What are the types of Queues?
4. State the difference between stacks and Queue?
5. List the applications of priority queues
6. Write the postfix and prefix notations for the following expression: A/B*C-D*E+F/G
7. State the basic operations that can be performed on queue.
8. List the operation of priority queue?
9. Define deque?
10. State the basic operations that can be performed on a stack.

Long Answer Questions [10 Marks]


1. What is a stack? What are various operations that can be performed on them? Explain with an example.
2. State any two applications of stacks and queues? With an example, explain infix to postfix conversion and
infix to prefix conversion algorithms.
3. Explain how queues can be implemented using arrays?
4. What is a queue? What are various operations that can be performed on them? Explain with an example
5. Write an algorithm to implement queue operations? Write Short notes on Circular Queue?

6. Implement circular queue using arrays


7. Explain how queues can be implemented using arrays.

8.Write a program to perform basic operations on stack.


9.Write an algorithm to insert and delete a key in a circular queue.
10. a)What are the drawbacks of queues? Discuss in detail about the circular queues.
(b) What is a dequeue? What are the various operations that can be performed on them? Explain.
UNIT – III: Trees
Short Answer Questions [2Marks]

1. List the steps in pre order traversal.


2. What do you mean by level of the tree and height of Tree?
3. State the properties of a Binary Tree?
4. Define a binary search tree? What is the use of threaded binary tree?
5. Define a complete binary tree and Full Binary Tree?
6. Define Max heap and AVL Tree?
7. What do you mean by Height Balanced Tree?
8. List out the properties of Red-Black trees?
9. Define Balance factor?
10. Differentiate between AVL tree and Binary search tree?

Long Answer Questions [10 Marks]


1. Explain the various representation of trees with example in detail
2. Define Binary Tree? Explain node structure and Representation of binary Tree?
3. Explain the various operations on a Binary tree with an example?
4. Write Binary Tree traversal for the given tree
A

B C

D E F G

H I
5. Define a binary search tree? With the help of suitable example, explain the insertion and deletion of
an element into binary search tree?
7. Construct a binary search tree from the given values. Consider the first value as the root value.
Values: 45, 23, 29, 85, 92, 7, 11, 35, 49, 51
8. What is an AVL tree? Explain various rotations of AVL trees maintaining balance factor while
insertion and deletion takes place.
8. What is an AVL Tree? How does it differ from a Binary tree?
9. Explain Heap tree in detail.
10. Explain Red-Black trees in detail.
UNIT – IV: Graphs & Searching

Short Answer Questions [2Marks]

1. Define Graph with an example and adjacent nodes in graph?


2. Define Directed graph and undirected graph?
3. Define out degree and in degree of graph?
4. Define BFS with an example.
5. Define DFS with an example.
6. What is searching?
7. What is linear searching?
8. What is binary Searching?
9. What is hashing? What do you mean by hash function?
10. What is collision? List out the Collision Resolution Techniques.
Long Answer Questions [10 Marks]

1. Explain the various representation of graph with example in detail.

2. Explain the two graph traversals techniques.

3. Write and explain Dijkstra algorithm for finding shortest path. Give an example.

4. Explain topological sorting algorithm for finding shortest path. Give an example.

5. Write and explain linear search procedure or algorithm with a suitable example.

6. Write and explain binary search procedure or algorithm with a suitable example.

7. (a) Compare binary search and linear search techniques.


(b) Find the number 77 from the following set of numbers using binary search:
6, 12, 17, 23, 38, 45, 77, 84, 90.

8. Explain hashing techniques with suitable examples.

9. What is collision? List various collision resolution techniques. Explain any two collision resolution
techniques.
10. Explain in detail about the following collision resolution methods:
(i) Linear probing. (ii) Separate chaining. (iii) Double hashing.
UNIT – V:Sorting

Short Answer Questions [2Marks]

1. What is the best case and worst case time complexity of Quick sort and insertion sort?
2. What is the best case and worst case time complexity of bubble sort and insertion sort?
3. What is the advantage of quick sort? Mention its worst case time complexity.
4. What is heap sort?
5. What is merge sort?
6. What is difference between quick sort and heap sort?
7. Define sorting and its types?
8. What are different types of internal sorting?
9. What is shell sort?
10. What is bubble sort?
Long Answer Questions [10 Marks]

1. Illustrate the working of merge sort with an example. Calculate the time complexity in worst and best cases.

2. Explain about insertion by sorting.

3. Explain about Heap sort.

4. Explain about bubble sort with algorithm.

5. Define Quick sort and explain it with Example.

6. Explain about two way sorting.

7. Explain about sorting by selection by sorting.

8. State and explain algorithm to perform Heap sort? Sort the following numbers using heap sort: 47, 32, 15, 38,
55, 17, 25, 45, 42 and 50.

9. What is meant by sorting? Write an algorithm for insertion sort and illustrate with an example?

10.Explain about shell sort with example.

You might also like