Master of Computer
Applications
MCA
II SEMESTER
203 – Data Structures
SCHOOL OF DISTANCE EDUCATION
ANDHRA UNIVERSITY
VISAKHAPATNAM - 530 003
All copyrights and privileges reserved by the School of Distance
Education. No part of the publication may be reproduced in any
form without the prior permission of the copyright owner.
Information relating to various courses may be obtained from the
office of the School of Distance Education, Andhra university,
Visakhapatnam - 530 003.
DIRECTOR
SCHOOL OF DISTANCE EDUCATION
ANDHRA UNIVERSITY, VISAKHAPATNAM - 3
SCHOOL OF DISTANCE EDUCATION
ANDHRA UNIVERSITY
VISAKHAPATNAM
Course Material Preparation Team
Name of the Author Practical. Nos.
Prof. P. S. Avadhani 1-27
Dept of Computer Science & Systems Engineering
AU College of Engineering, Visakhapatnam.
Course Co-ordinator & Editor
Dr. G. Samuel Vara Prasad Raju
Asst. Professor of Computer Science
School of Distance Education
Andhra University
Visakhapatnam.
iii
CONTENTS
Lesson No NAME OF THE LESSON Page No.
1. Abstract Data Types & Review of Strings 1
2. Multidimensional Arrays 11
3. Sparse Matrices and Palynomials 25
4. Stacks 37
5. Recursion 57
6. Efficiency of Recursion 63
7. Queues 65
8. Special Types of Queues 77
9. Linked Lists 85
10. Doubly Linked Lists 103
11. Trees 117
12. Binary Trees 121
13 Traversals of a Binary Tree 131
14. Binary Search Trees 139
15. Threaded Binary Trees 153
16. Searching Techniques 159
17. Hashing 167
18. Basic Terminology of Graphs 177
19. Graph Representation 183
20. Graph Traversals 187
21. Shortest Path Problem 193
22. Dijkstra’s and Floyd’s Algortfims 199
23. Transitive Closure and Warshall’s Algorithm 207
24. Minimum Spanning Trees 213
25. Insertion and Bubble Sort Algorithms 221
26. Merge Sort Algorithm 227
27. Heap Sort Algorithm 233