
Multiparadigm Programming
Code
8285
Academic unit
Faculdade de Ciências e Tecnologia
Department
Departamento de Informática
Credits
6.0
Teacher in charge
Artur Miguel de Andrade Vieira Dias, Luís Manuel Marques da Costa Caires
Weekly hours
4
Total hours
59
Teaching language
Português
Objectives
Knowledge
1 - Understand the characteristics, motivations and opportunities of application of some of the dominant programming paradigms.
2 - Understand the advantages of being fluent in diverse programming styles and use them in an integrated way.
3 - Understand the general principles that govern the growth of a multiparadigm language.
Skills
4 - Be able to develop complex programs, exploring available linguistic ingredients.
5 - With a critical mind, be able to find solutions that can be expressed as simply and directly as possible.
6 - Ability to use the paradigms alone or integrated.
7 - Acquire experience in the use a particular multiparadigm programming system - Scala.
Prerequisites
Prior experience with a functional language, e.g. OCaml, and an object-oriented language, eg Java.
Subject matter
A - Multiparadigm programming: Characterization, motivation and examples. The Creative Extension Principle.
B - Functional Programming: Evaluation strategies. Lazy evaluation and infinite data structures. Streams. Comprehensions. Algebric data types and pattern-matching. Continuations. Monads.
C - Imperative programming: State. Control. Iterators.
D - Object-oriented programming: Classes. Traits. Mixins. Family polymorphism.
E - Types: Nominal types. Structural types. Compounds types with refinements. Subtypes. Views. F-bounded polymorphism. Lower bounds. Variance annotations.
F - WEB Programming: XML processing using patterns based on regular expressions.
G - Concurrent programming: The Actor model. Futures. Parallel computations. Asynchronous and Synchronous Channels. Data parallelism.
Bibliography
- Martin Odersky, Lex Spoon, and Bill Venners, "Programming in Scala", Artima, 2011.
- Peter van Roy, Seif Haridi, "Concepts, Techniques, and Models of Computer Programming", The MIP Press, 2004.
- Martin Odersky, "Scala by Example", Programming Methods Laboratory, EPFL, 2014.
- Martin Odersky, "The Scala Language Specification", version 2.9, Programming Methods Laboratory, EPFL, 2014.
- Artur Miguel Dias, "Course notes, including exercices list", 2014.
Teaching method
In the lectures, the concepts are presented, exemplified and discussed.
In the lab classes, the students solve small problems, applying the concepts and techniques learned.
The three projects of the course are mainly developed outside the classes.
Evaluation method
Assessment components
The assessment components are the following and have the weights on the final score that are shown:
- T1 - Mid-term test 1 - 35%
- T2 - Mid-term test 2 - 35%
- PP - Programming projects - 30%
- ER - Resit exam - 70%
Each of these elements is graded up to 20 points.
The value of PP is the arithmetic mean of 3 programming projects. There is no minimum score on any of them. The projects are carried out by groups of one or two students. There may be discussions of some projects for some groups.
Grades of the practical and theoretical components
The grade of the practical component is defined as:
- PRAT = PP
The grade of the theoretical component is defined in two diferent ways, depending on when the grade is obtained:
- TEOR= (T1 + T2) / 2
- TEOR = ER
Frequência
The "frequência" grade is the same as the practical component:
- FREQ = PRAT
"Frequência" is an essential element to pass this course. The ERASMUS students can make the projects from a distance.
Final grade and Success
The final grade is calculated using the formula:
- FINAL = 0.3 * FREQ + 0.7 * TEOR
Sucess depends on the following condition:
- Success = FREQ >= 9.5 and TEOR >= 9.5
All the intermediate grades are rounded to two decimal places.
The final grade is an integer number.
Validity of the "frequência" obtained this year
The "frequência" grade obtained in the current school year will be valid in the next school year, at least.
Frequências from the previous years
All "frequência" grades obtained in previous years are valid in the current school year. It is not possible to improve a frequência grade obtained in the past.
Academic fraud
Any type of fraud in any component of the assessment causes the student to imediatelly fail to pass the course in the current academic year (even if there are exams scheduled). This applies both to those students who give information as to who receive information.