Programming Paradigms Wednesdays 12:30–16:15 · room 2.2.120

Programming
Paradigms

SW7 · Autumn 2026
Aalborg University Copenhagen

⌄
Layers, spirals, flow lines and composed shapes: data, control, communication, types

Programming Paradigms

SW7 · Autumn 2026 · Aalborg University Copenhagen

This course examines key design decisions and major differences between programming languages, focusing on characteristics such as state, control flow, process communication, data types and modularity.

These decisions shape everyday engineering: git branches instantly because it never overwrites data, allowing access to all previous states; WhatsApp serves hundreds of millions of users on message-passing concurrency; Android adopts Rust because most security vulnerabilities are memory errors that the language design rules out through its type system. These concepts, however, have a wider scope than any single technology or programming language that only make some design choices default. As AI assistants generate more of the code, recognizing the paradigm beneath an unfamiliar program becomes a core engineering skill. In this course, we will learn to identify and apply these design decisions through study, practice, and implementation.

Thirteen sessions, every Wednesday 12:30–16:15: a 2×45 min lecture, then a 2 h lab with homework. We already know Java, C#, Python and some C; we will read and write OCaml and other languages as the ideas require them.

Sessions

Part 1 Data & control sessions 2-5

How a program holds its data and decides what runs next: data that is never overwritten, values defined by their cases or by their operations, recursion and folds, and functions handed around as values to drive a traversal or to delay a computation.

DateSession
09 SepWhyTestStory02 Persistent and Ephemeral Data Structures
Block 1Persistent data structures PDF
Block 2Introduction to OCaml PDF·OCaml
Lab
Warm-upThe two-list queue, on paper PDF·solutions
QuestOne queue, three languages HTML·solutions
Block 1 Persistent data structuresPDFWarm-upThe two-list queue, on paperPDF·solutions
Block 2 Introduction to OCamlPDF·OCamlQuestOne queue, three languagesHTML·solutions
16 SepWhyTestStory03 Algebraic Data Types and Objects
Block 1Two ways to be a value HTML·PDF
Lab
Warm-upA notification as a type PDF·OCaml·solutions
QuestA little music language HTML·GitHub·solutions
Block 1 Two ways to be a valueHTML·PDFWarm-upA notification as a typePDF·OCaml·solutions
QuestA little music languageHTML·GitHub·solutions
23 SepWhyTestStory04 Functional Programming and Control
Block 1Control patterns HTML·PDF
Block 2The λ-calculus HTML·PDF
Lab
Warm-upThe λ-calculus on paper PDF·solutions
QuestAn evaluator for the λ-calculus HTML·GitHub·solutions
Block 1 Control patternsHTML·PDFWarm-upThe λ-calculus on paperPDF·solutions
Block 2 The λ-calculusHTML·PDFQuestAn evaluator for the λ-calculusHTML·GitHub·solutions
30 SepWhyTestStory05 Functions as Values: Iterators and Streams
Block 1Iterators HTML·PDF
Block 2Thunks and streams HTML·PDF
Lab
Warm-upLists, then Pascal's triangle PDF·solutions
QuestMaking a mini text editor HTML·GitHub·solutions
Block 1 IteratorsHTML·PDFWarm-upLists, then Pascal's trianglePDF·solutions
Block 2 Thunks and streamsHTML·PDFQuestMaking a mini text editorHTML·GitHub·solutions

Part 2 Coordination & communication sessions 6-9

Language constructs for concurrent and distributed programming, on one system, a bank, built four ways: on one thread with async and await, with threads that share memory, with processes that pass messages, and across machines that can fail.

DateSession
07 OctWhyTestStory06 Asynchronous Programming
Block 1Coordination & communication HTML·PDF
Block 2Asynchronous programming HTML·PDF
Lab
Warm-upThe lecture in JS and Python PDF
QuestContinuations (optional) HTML·GitHub
Block 1 Coordination & communicationHTML·PDFWarm-upThe lecture in JS and PythonPDF
Block 2 Asynchronous programmingHTML·PDFQuestContinuations (optional)HTML·GitHub
21 OctWhyTestStory07 Multi-ThreadingNotes
Block 1Mutual exclusion HTML·PDF
Block 2Atomics; independence of the order HTML·PDF
Lab
Warm-upFour Java classes HTML·GitHub
QuestA mini ray tracer HTML·GitHub
Block 1 Mutual exclusionHTML·PDFWarm-upFour Java classesHTML·GitHub
Block 2 Atomics; independence of the orderHTML·PDFQuestA mini ray tracerHTML·GitHub
04 NovWhyTestStory08 Message PassingNotes
Block 1Determinism, choice and buffer capacity HTML·PDF
Block 2Actors and mailboxes HTML·PDF
Lab
Warm-up Coming soon
Quest Coming soon
Block 1 Determinism, choice and buffer capacityHTML·PDFWarm-upComing soon
Block 2 Actors and mailboxesHTML·PDFQuestComing soon
11 Nov09 Failure and RecoveryNot given this year

Part 3 Types & abstraction sessions 10-13

What a type system guarantees before a program runs: static types, polymorphism, and abstraction that hides a representation behind its operations; the course closes with declarative programming.

DateSession
16 NovWhyTestStory10 Static Type Systems
Block 1Typing of a functional language HTML·PDF·Demo
Block 2Typing of an imperative language HTML·PDF
Lab
Warm-upIn-class exercises on typing PDF·solutions
QuestSemantics and typing of break and continue PDF·solutions
Block 1 Typing of a functional languageHTML·PDF·DemoWarm-upIn-class exercises on typingPDF·solutions
Block 2 Typing of an imperative languageHTML·PDFQuestSemantics and typing of break and continuePDF·solutions
18 NovWhyTestStory11 Polymorphism
Block 1Polymorphism and type inference HTML·PDF
Lab
Warm-upExercises on monomorphic and polymorphic typing PDF·solutions
QuestAlgorithm W in OCaml HTML·GitHub·solutions
Block 1 Polymorphism and type inferenceHTML·PDFWarm-upExercises on monomorphic and polymorphic typingPDF·solutions
QuestAlgorithm W in OCamlHTML·GitHub·solutions
25 NovWhyTestStory12 Data Abstraction
Block 1
Block 2
Lab
Warm-up
Quest
Block 1 Warm-up
Block 2 Quest
02 DecWhyTestStory13 Declarative Programming and Conclusion
Block 1
Block 2
Lab
Warm-up
Quest
Block 1 Warm-up
Block 2 Quest

Materials

Slides, handouts, lab code and solutions live in the course repository, linked from each session page as the course runs. Clone it once and git pull for updates.

Topics, languages and lab material appear for each session as we reach it — later sessions may still change.