# ALGORITHMS AND DATA STRUCTURES

## Learning outcomes of the course unit

The goal of the course is to familiarize students with algorithms, data structures and with the techniques needed for analyzing their eﬃciency.

Knowledge and understanding:

The main objective of this course is to acquire the tools and techniques needed to analyze and design practical algorithmic solutions to elementary real-world problems. This course gives students an in-depth understanding of a wide range of fundamental algorithms and data structures used in developing structured, efficient, reusable, and practical software.

Applying knowledge and understanding:

Students will be able to compare different algorithms for the same task, and predict or guarantee performance for large problems. Students will be able to study the inherent difficulty of the given problem, to model and implement efficient software solutions using appropriately selected algorithms and data structures.

## Course contents summary

This course presents an introduction to the most important data

structures and to the techniques for designing and analyzing computer algorithms.

General topics include asymptotics, solving recurrence, algorithm design, analysis of algorithms

and data structures.

## Course contents

• Undecidability, intractability of computational problems.

• Computational complexity: models of computation, analysis of algorithms.

• Divide and conquer technique, recurrence relations, the main Lemma.

• Basic data structures: linked lists, stacks, queues, trees.

• Comparison-based sorting algorithms: Insertionsort, Mergesort, Quick-

sort, Heapsort.

• Lower bounds for sorting and searching.

• Sorting in linear time.

• Median and order statistics.

• Introduction to dynamic programming and Greedy technique.

• Binary trees, binary search trees, AVL trees, B-trees.

• Hash tables.

• Graphs, BFS,DFS, DAG, topological sort, strong components.

• Union-ﬁnd, MST, Kruskal’s algorithm, Prim’s algorithm.

• Dijkstra’s algorithm, Bellman-Ford algorithm.

## Recommended readings

• T. H. Cormen, C. E. Leiserson, R. L. Rivest, C. Stein. Introduction to algorithms, MIT Press, third edition, 2011.

• C. Demestrescu, I. Finocchi, G. F. Italiano, Algoritmi e strutture dati, McGraw Hill, seconda edizione, 2008.

• P. Crescenzi, G. Gambosi, R. Grossi. Strutture di Dati e Algoritmi, Pearson, prima edizione, 2006

## Teaching methods

Class, exercises. Meanwhile (Lab of “Fondamenti di Programmazione B”) some of the most significant data structure are implemented in C++.

## Assessment methods and criteria

Written and oral examination. Written examination includes a number of exercises some of which are simple variants of exercises given in class, others are totally new, but can be solved by using the techniques discussed in class.

Students can get the minimum grade by solving the exercises of the first kind.