You are on page 1of 8

Course Number: CSE212

Course Name: Data Structures ad


Algorithms

Credits: 4

Contact hours / week:


Lecture Tutorial Practical
2
1
2
Co-Instructor(s): Juhi Pruthi

Instructor: Triloki Pant

III Semester: 2015-16


Course Description
This course covers some of the general purpose data structures. It is aimed at helping the
students to understand the reasons for choosing data structures. The main objective of the course
is to teach the students how to select and design data structures and algorithms that are
appropriate for problems they might encounter. The topics to be covered include Array, Stacks,
Queues, Linked List, Trees, Heap, Graphs, Searching and Sorting.
Course Outline
Introduction to Data Structures and Algorithms, Primitive and Non-Primitive Data Structures,
Time and Space complexity, Array and operations on arrays, Dynamic array and dynamic memory
allocation, Stack and its applications, Queue and its applications, Circular and Double ended
queues, Linked Lists, Doubly linked list, Linked representation of Stacks and Queues, Applications
of linked lists, Trees and types of trees, Binary trees, Conversion of general trees into binary trees,
Traversing of binary tree, Efficient Binary Search Trees-AVL Tree, Applications of Trees, Binary
heaps, Graphs and their Applications, Searching and Sorting algorithms and their comparison.
Pre-requisites
C Programming, Elementary Mathematics
Required Books
Text Books
1. Data Structures using C, Reema Theraja, Oxford University Press, 2nd Edition, ISBN
9780198099307.
Reference books (available in the library)
1. Data Structures using C, Seymour Lipschutz, Mc Graw Hill, ISBN 9780070701984.
2. Data Structures using C and C++ Langsam, Augenstein and Tannenbaum,Eastern Economy
Edition PHI, 2nd Edition, ISBN 9788120311770.
Learning Resources
The instructor will post regularly the learning resources available on the web related to the
concerned topics.
Course Objectives / Learning Outcomes
Upon successful completion of this course, students should be able to:
1. Understand various data structures that serve as building blocks for creating efficient
programs. (ABET a)
2. Design, analyze and implement basic data structures. (ABET b)
3. Calculate the time complexity for evaluating the performance of the algorithms. (ABET a, b)

Course Name

III Semester

Page 1 of 8

4. Implement linked list data structures which are a preferred data structure when dynamic
memory allocation is required. (ABET k)
5. Learn about different data structures like arrays, stacks, queues, trees, binary search trees,
graphs and their applications. (ABET k)
6. Apply appropriate data structure based on the requirement of the problem. (ABET a, k)
7. Choose the appropriate algorithm design method for a specified application. (ABET c)
8. Solve problems using different data structures and write corresponding programs. (ABET c,
e)
9. Select efficient sorting and searching techniques to solve common programming problems.
(ABET e, k)
Course plan
Sessions
12

Topic

Competencies and
Evaluation (Integration)

Topic: Introduction to data structures and


algorithms

Competencies:
To identify various types of data
structures for problem solving
To estimate the time and space
complexity of simple algorithms

Relevance (5 min):
Introduction and application of data
structures in various problems
Application of algorithms as per their time
Tutorial 1:
complexity
Designing algorithms for simple
Activation (10 min):
problems
Quick introduction to programming
Estimation of time complexity for
Demonstration (20 min):
elementary algorithms
Estimating the time complexity of simple
program segments, e.g., assignments, loops Lab. 1:
Estimation of time complexity of simple
Quick review of C programming,
algorithms
exercise on pointers and arrays
Estimation of space complexity
Application (10 min):
Problem solving techniques using data
structures
Selection of appropriate data structures
Reference: Text bookChapter 2, Reference book 1
Chapter 1, Reference book 2Chapter 1

Course Name

III Semester

Page 2 of 8

34

Topic: Array and its applications


Activation (10 min):
Quick revision of previous lecture
Demonstration (30 min):
Array creationstatic and dynamic array
Dynamic memory allocation
Performing basic operations on arrays
adding and deleting elements, merging
Applications (5 min):
Array applications for storing data,
searching and sorting data

Competencies:
To create static and dynamic arrays
and perform basic array operations
To arrange the elements in arrays in
sorted sequence

Tutorial 2:
Create dynamic array of the size
defined at the time of compilation
Arrange the array in sorted
sequence
Addition and deletion of elements in
the array
Reference: Text BookChapter 3, Reference book 1 Lab. 2:
Chapter 4, Reference book 2Chapter 1
Implement the programs related to
arrays
510

Topic: Stack, Queues and their applications


Activation (10 min):
Quick revision of previous lecture
Demonstration (30 min):
Performing basic stack and queue
operations-creation, addition, deletion
Generation of dequeue and addition and
deletion of elements to it
Implementation of circular queue
Applications (5 min):
Recursive calls using stacks
Polish notation generations and evaluation
using stacks
Job scheduling using queues and priority
queues

Competencies:
To create stack of elements and
implementation of basic stack
operations
To apply stacks in various
applications, e.g., recursive calls,
prefix and postfix expression
evaluation
To create queues of items and
perform basic queue operations
Differentiate and generate various
types of queues

Tutorial 3, 4, 5:
Implementation of stack using array
and dynamic array
Reference: Text BookChapter 7, 8, Reference book
Implementation of queue using
1Chapter 6, Reference book 2Chapter 2, 4
array
Implementation of stack using
queues
Implementation of queue using
stacks
Implementation of dequeue and
circular queue
Lab. 3, 4, 5:
Implement the programs related to
stacks and queues
Assignment 1:
Sorting the elements using stacks
and finding the time complexity of
this algorithm
Conversion of infix expression into
prefix and postfix expression

Course Name

III Semester

Page 3 of 8

1113

Topic: Linked list and its applications


Activation (10 min):
Quick revision of previous lecture
Demonstration (30 min):
Creation of linked list, deletion of elements
Doubly linked list generation and visit
Circular linked list generation
Basic operations on linked lists

Competencies:
To create linked list of items and
visit the items, perform basic list
operations
To generate doubly linked and
circular linked list
Tutorial 6:
Designing Stack with the linked list
and perform the basic stack
operations
Sorting the elements of given linked
list

Applications (5 min):
Application of linked lists in data
representation
Linked implementation of stacks and queues Lab. 6:
Implement the programs related to
Reference: Text BookChapter 6, Reference book 1
linked list
Chapter 5, Reference book 2Chapter 4
Quiz 1:
Quiz based on the topics covered up
to Linked list and its applications

Course Name

III Semester

Page 4 of 8

1421

Topic: Trees, types of trees and their applications

Competencies:
To identify various types of trees
Activation (5 min):
including rooted and binary trees
Quick revision of previous lecture
To generate binary trees from given
trees
Demonstration (35 min):
To traverse a binary tree
Creation of trees, rooted trees and binary
To utilize binary tree for expression
trees
evaluation
Conversion of a tree into binary tree
To estimate the time and space
Creation of expression tree
complexity of tree traversal
Traversing trees using inorder, preorder and
algorithms
postorder visit
Solving infix, prefix and postfix expressions Tutorial 7, 8, 9, 10:
Creation of BST and BST traversal
Create binary tree from given rooted
Searching through BST
tree
Designing algorithms for traversing
Applications (5 min):
binary trees-inorder, preorder and
Representation of trees for hierarchical data
postorder visit
representation
Solving binary expressions using
Checking the syntax of expressions involving
expression trees
binary expressions
Generating binary search tree from
Application of BST for efficient search
given data set and searching the
elements
Reference: Text BookChapter 9, 10, Reference
Finding the time complexity of
book 1Chapter 7, Reference book 2Chapter 5, 7
searching through BST
Lab. 7, 8, 9 10:
Implement the programs related to
trees, binary trees and BST
Assignment 2:
Create a circular linked list and print
the elements
Visit the elements of a doubly linked
list and delete given element
Generate an expression tree for a C
assignment statement and evaluate
it
Write the algorithm for creation of a
BST

Course Name

III Semester

Page 5 of 8

2225

Topic: Efficient binary search trees with applications Competencies:


To generate AVL trees
Activation (10 min):
To create binary heaps and sorting
Quick revision of previous lecture
the elements using heapsort
algorithm
Demonstration (30 min):
Problem with the skewed trees and their
Tutorial 11, 12:
solution-height balance trees
Generating height balanced trees
AVL tree generation-addition and deletion
using AVL tree
of elements, Rotations
Sorting the elements using heapsort
Generation of binary heaps
Comparison of BST and AVL tree in
Addition and deletion of elements in binary
terms of searching
heaps
Lab. 11, 12:
Applications (5 min):
Implement the programs related to
Applications of AVL trees in searching
AVL trees and heaps
Sorting using binary heaps
Reference: Text BookChapter 10, 12, Reference
book 1Chapter 7, Reference book 2Chapter 6, 7

2628

Topic: Graphs and applications of graphs


Activation (5 min):
Quick revision of previous lecture
Demonstration (35 min):
Generation of simple graph, connected
graph, directed and undirected graph
Illustration of planar graph, bipartite graph
Visiting the graphs using DFS and BFS
algorithms
Finding spanning trees and MST in given
graphs
Estimation of shortest path between two
nodes in a given weighted graph
Applications (5 min):
Shortest path finding problems
Application of graphs in network
representation and data flow in networks
Graph coloring problems
Reference: Text BookChapter 13, Reference book
1Chapter 8, Reference book 2Chapter 8

Competencies:
To understand various types of
graphs, e.g., complete, planar,
bipartite graphs
To generate the spanning trees and
minimum spanning trees from given
graphs
To find the shortest paths for given
pair of nodes
Tutorial 13, 14:
Finding spanning trees from given
graphs
Visit the graphs in DFS and BFS
manners
Lab. 13, 14:
Implement the programs related to
graphs
Assignment 3:
Find various types of height
balanced trees
Compare BST and binary heap
Compare the DFS and BFS algorithms
Find the algorithm to detect the
cycles in given graphs
Quiz 2:
Quiz based on the topics covered up
to Graphs and applications of graphs

Course Name

III Semester

Page 6 of 8

2932

Topic: Searching and sorting algorithms

Competencies:
To search a given item from the list
Activation (5 min):
of items
Quick revision of previous lecture
To sort the given data
Demonstration (35 min):
To compare various sorting
Searching of an item from unsorted data set
algorithms in terms of time
Searching a data item from a sorted list
complexity
Demonstration of sorting algorithms: bubble
sort, insertion sort, selection sort
Tutorial 15, 16:
Comparison of sorting algorithms
Search a given number from the
Applications (5 min):
given set of numbers (sorted and
Applications of searching algorithms in
unsorted)
searching numbers
Sort the given data set using
Searching strings from given text
different sorting techniques and
Sorting numbers in ascending/descending
compare the steps
order
Find the time complexity of each
Sorting data items/files/strings
technique
Reference: Text BookChapter 14, Reference book
1Chapter 9, Reference book 2Chapter 6, 7

Lab. 15, 16:


Implement the programs related to
searching and sorting
Assignment 4:
Searching in constant time using
hashing
Finding the lower bound of sorting
algorithms

Evaluations
The final grade will be based on the marks / grades obtained in the following list of evaluation
components:
The percentage allocations are listed below:
Mid Semester Exam (open/close book)..........................
15%
End Semester Exam (open/close book) ..........................
35%
Continuous evaluation (Quiz/Assignment) ...................
20%
Lab experiments/projects ...........................................
30 %

Mid-term examination:
Semester-end examination:

Course Name

III Semester

Page 7 of 8

Course Policies
1. Attendance policy
Students are expected to attend class regularly. Failure to attend class regularly and adhere to the expected
attendance percentage will result in a reduction of the grade as per the Universitys grading policies. As
specified in the Academic Regulations, for a specific course, if the attendance is less than 80% overall, a
students grade will be reduced by one letter grade. For example, if the students grade is A+ at the end of
the semester it will be reduced to B+ and so on. For attendance less than 50% the final grade for the student
in the course will be an F.
2. Make-up policy
No make-up work will be given for unexcused absences. Faculty needs to be informed in advance in case
the student is not going to be able to submit assignment/take a quiz, etc., and it is at the discretion of the
faculty to sanction make up work or make up for an evaluation component.
3. Violations of honor code:
Listed below are some examples of violations, all of which will be sent to the Disciplinary Action
Committee:
Copying answers or portions of homework/ assignment/ assessment/project/ quiz or any work given by the
faculty. This includes copying from someone else or from the internet or from any other material.
Letting another student copying from you before or during or after class. This includes allowing of copying
answers or portions of homework/ assignment/ assessment/project/ quiz or any work given by the faculty,
Any student found giving proxy attendance for someone else will be penalized as per the facultys
discretion. The student for whom proxy attendance is given will also be penalized.
4. General policy
The use of mobile phones/ laptops for personal purposes is strictly prohibited. In case the student is found
to be violating this, the decision to reprimand is as per the facultys discretion.
The student is supposed to concentrate in the class on the teaching-learning going on. Doing any
unassigned work / assignment/ assessment in the class is not allowed and if the student is found to be
violating this, the decision to reprimand is as per the facultys discretion.

Course Name

III Semester

Page 8 of 8

You might also like