Functional Programming
Funktionell programmering
About the Syllabus
Grading scale
Course modules
Position
The course is mandatory within Computer Science, bachelor´s programme (N1COS).
The course can be part of the following programmes:
- Computer Science, Master's Programme (N2COS)
- Software Engineering and Management Master's Programme (N2SOF)
- Bachelor's Programme in Mathematics (N1MAT)
- Mathematical Sciences, Master's Programme (N2MAT)
The course is a also a single-subject course at Gothenburg University.
Main field of study with advanced study
Entry requirements
- A completed course in programming with at least 7.5 credits.
Applicants must prove knowledge of English: English 6/English level 2 or the equivalent level of an internationally recognized test, for example TOEFL, IELTS.
Content
This course introduces students with prior programming experience to a functional programming language and its core concepts. The primary goal is to enable students to apply the functional approach to writing realistic small- to medium-sized programs, while also helping them transfer their general programming skills into the functional programming paradigm.
Concrete topics encountered in the course include:
- defining (pure) functions,
- pattern matching,
- guards,
- recursion,
- data types,
- basic and compound data types (e.g., lists and tuples),
- user-defined algebraic data types,
- recursive data types,
- modelling with data types,
- functions as first-class values,
- lambda expressions,
- partial application,
- currying,
- composition,
- higher-order functions,
- list comprehensions,
- introduction to equational reasoning,
- parametric polymorphism and type classes,
- modules and abstract data types,
- lazy evaluation and infinite values,
- introduction to monads and IO,
- efficiency of functional programs,
- property-based testing.
Objectives
After completion of the course the student should be able to:
Knowledge and understanding
- describe the basic concepts of modern functional programming languages, such as recursion, pattern matching, polymorphism, first-class functions, higher-order functions, purity and immutability, and lazy evaluation,
- describe a basic repertoire of functional programming techniques, such as algebraic data types, currying, infinite data structures, monads, and the role of data types in modelling and problem solving.
Skills and abilities
- write small to medium-sized functional programs for a variety of applications,
- utilize a diverse range of programming techniques characteristic of functional programming, including recursion, modelling with recursive data types, abstraction and reuse through higher-order functions, as well as leveraging polymorphism and monads,
- implement effective tests for functional programs with the help of suitable tools.
Judgement ability and approach
- show the ability, in various contexts, to judge which programming techniques are most appropriate for solving the problem at hand
- identify the strengths and possible weaknesses of the functional programming paradigm, compared to other programming paradigms.
Sustainability labelling
Form of teaching
Lectures, computer labs, and exercises.
Language of instruction: English
Examination formats
The course is examined by an individual written exam carried out in an examination hall at the end of course, and several compulsory lab assignments carried out in groups.
If a student who has been failed twice for the same examination element wishes to change examiner before the next examination session, such a request is to be granted unless there are specific reasons to the contrary (Chapter 6 Section 22 HF).
If a student has received a certificate of disability study support from the University of Gothenburg with a recommendation of adapted examination and/or adapted forms of assessment, an examiner may decide, if this is consistent with the course’s intended learning outcomes and provided that no unreasonable resources would be needed, to grant the student adapted examination and/or adapted forms of assessment.
If a course has been discontinued or undergone major changes, the student must be offered at least two examination sessions in addition to ordinary examination sessions. These sessions are to be spread over a period of at least one year but no more than two years after the course has been discontinued/changed. The same applies to placement and internship (VFU) except that this is restricted to only one further examination session.
If a student has been notified that they fulfil the requirements for being a student at Riksidrottsuniversitetet (RIU student), to combine elite sports activities with studies, the examiner is entitled to decide on adaptation of examinations if this is done in accordance with the Local rules regarding RIU students at the University of Gothenburg.
Grades
Sub-courses
- Written hall examination, 4,5 credits
Grading scale: Pass with distinction (5), Pass with credit (4), Pass (3) and Fail (U). - Laboratory, 3 credits
Grading scale: Pass (G) and Fail (U)
The grading scale comprises: Pass with distinction (5), Pass with credit (4), Pass (3) and Fail (U).
To pass the course, students must receive a passing grade in both modules. The grade for the entire course will be determined by the written exam.
Course evaluation
The course is evaluated through meetings both during and after the course between teachers and student representatives. Further, an anonymous questionnaire is used to ensure written information. The outcome of the evaluations serves to improve the course by indication which parts could be added, improved, changed or removed.
Other regulations
The course is a joint course together with Chalmers.
The course replaces the course DIT143, 7.5 credits. The course cannot be included in a degree which contains DIT143. Neither can the course be included in a degree which is based on another degree in which the course DIT143 is included.
The course cannot be included in a degree programme where course DIT441 Introduction to Functional Programming is included, or any other degree which is based on a degree which includes DIT441.