Credits
6
Types
Compulsory
Requirements
This subject has not requirements
, but it has got previous capacities
Department
CS
Teachers
Person in charge
- Gabriel Valiente Feruglio ( gabriel.valiente@upc.edu )
Weekly hours
Theory
2
Problems
2
Laboratory
0
Guided learning
0
Autonomous learning
6
Competences
Knowledge
Skills
Competences
Objectives
-
Understand iterative algorithms and their implementation in a modern programming language, and apply them to solve problems.
Related competences: K3, K4, S7, S8, C6, -
Understand recursive algorithms and their implementation in a modern programming language, and apply them to solve problems.
Related competences: K3, K4, S7, S8, C6, -
Compare solutions regarding time and memory use and choose the most appropriate solution.
Related competences: K3, K4, S7, S8, C6,
Contents
-
Introduction
Introduction. Recapitulation of Applied Programming 1. Introduction to Python. Functions, scoping, and abstraction. Structured types and mutability. -
Recursion
Recursion. Recursive design. Simple recursion. Multiple recursion. Tail recursion. Tail recursion elimination. Examples. -
Object-oriented programming
Introduction to object-oriented programming. Abstract data types, classes, and methods. Encapsulation, inheritance, shadowing. Examples. -
Algorithm analysis
Algorithm analysis. Cost in time and space. Worst, best, and average case. Asymptotic notation. Analysis of the cost of iterative algorithms. Analysis of the cost of recursive algorithms. Recurrences. Solution methods. Examples. -
Divide and conquer
Divide and conquer. Principles: partition into subproblems, recombination of solutions. Examples. -
Dynamic programming
Dynamic programming. Principles: partition into overlapping subproblems, memoization, tabulation. Top-down dynamic programming. Bottom-up dynamic programming. Examples.
Activities
Activity Evaluation act
Theory
4h
Problems
4h
Laboratory
0h
Guided learning
0h
Autonomous learning
7.5h
Theory
6h
Problems
6h
Laboratory
0h
Guided learning
0h
Autonomous learning
22.5h
Theory
4h
Problems
6h
Laboratory
0h
Guided learning
0h
Autonomous learning
15h
Theory
4h
Problems
4h
Laboratory
0h
Guided learning
0h
Autonomous learning
15h
Theory
2h
Problems
4h
Laboratory
0h
Guided learning
0h
Autonomous learning
7.5h
Theory
6h
Problems
6h
Laboratory
0h
Guided learning
0h
Autonomous learning
22.5h
Mid-term exam
Week: 7 (Outside class hours)
Theory
0h
Problems
0h
Laboratory
0h
Guided learning
0h
Autonomous learning
0h
Final exam
Week: 14 (Outside class hours)
Theory
0h
Problems
0h
Laboratory
0h
Guided learning
0h
Autonomous learning
0h
Teaching methodology
In the theoretical sessions, the lecturer will introduce algorithmic and programming concepts, combined with examples and problem-solving. In the problem-solving sessions, students will work on their own solving problems, under supervision and assistance of the lecturer.Evaluation methodology
There will be two exams: a mid-term exam and a final exam. The grade will be the largest of the final exam grade and the average of the mid-term grade and the final exam grade.The students who do not pass the subject can take the reexamination exam. In this case, the final grade will be the one of this exam.
Bibliography
Basic
-
Introduction to computation and programming using Python : with application to understanding data
- Guttag, John,
The MIT Press,
2021.
ISBN: 9780262363433
https://research-ebsco-com.recursos.biblioteca.upc.edu/c/ik5pvi/search/details/mlj5v5o4zf?db=nlebk
Complementary
-
Introduction to algorithms
- Cormen, Thomas H.; Leiserson, Charles E.; Rivest, Ronald L.; Stein Clifford,
The MIT Press,
2022.
ISBN: 0262367505
https://research-ebsco-com.recursos.biblioteca.upc.edu/c/ik5pvi/search/details/lq2sgumirf?db=nlebk