Informatik für D-ITET - FS 19

Course catalog: 252-0848-00L
Lecturers: Malte Schwerhoff, Hermann Lehner

Primary educational objective is to learn programming with C++. After having successfully attended the course, students have a good command of the mechanisms to construct a program. They know the fundamental control and data structures and understand how an algorithmic problem is mapped to a computer program. They have an idea of what happens "behind the scenes" when a program is translated and executed. Secondary goals are an algorithmic computational thinking, understanding the possibilities and limits of programming and to impart the way of thinking like a computer scientist.

The course covers fundamental data types, expressions and statements, (limits of) computer arithmetic, control statements, functions, arrays, structural types and pointers. The part on object orientation deals with classes, inheritance and polymorphism; simple dynamic data types are introduced as examples. In general, the concepts provided in the course are motivated and illustrated with algorithms and applications.

Date Message

The exam solution is now available.


Bonus exercise 3 (Binary Search Tree) is available. Good luck!


Bonus exercise 2 (Sudoku) is available. And best of all, only 1XP required to unlock it ;) Good luck!


Bonus exercise 1 (Tic-Tac-Toe) is available. Good luck!


Registration to the exercise sessions is open:

Register now on [code]expert

Welcome to Informatik I für D-ITET! We will use a Slack channel for fast and informal communications of general interest. Please join using the following Slack Channel Invitation.

This is a plan. No plan survives contact with reality. We will constantly update lecture material before the lectures.

Week Date Topic Lecture Additional Material Exercises P Prerequisites to unlock bonus exercises B Bonus exercises
1 21.02 Introduction - Integer Arithmetic and its Limits Organisation
Integer Arithmetic Lecture
Handout DE ❘ EN
Lecture Examples
Summary 01 | 02
Organisational Information
C++ Tutorial
[code]expert How-To
2 28.02 Boolean Functions, Safe Programming, Control Flow I Lecture
Handout DE ❘ EN
Lecture Examples
Ausdruckswert (Clicker)
Ariane 5 Video ❘ Details
Summary 03
Exercise 2
3 07.03 Control Flow II, Floating Point I Lecture
Handout DE ❘ EN
Lecture Examples
For-Loop (Clicker)
Summary 04
Exercise 3
Self-Assessment I (Moodle)
Self-Assessment I (PDF) - Solution
4 14.03 Floating Point II, Functions I Lecture
Handout DE ❘ EN
Lecture Examples
IEEE-754 Converter
Summary 05
Exercise 4
Comparing Floating Points
Floating Point Guidelines
5 21.05 Functions II, Reference Types I Lecture
Handout DE ❘ EN
Lecture Examples
Summary 06
Exercise 5
Function Exercise 1 | 2
Stepwise refinement
Self-Assessment II (Moodle)
Self-Assessment II (PDF) - Solution
6 28.03 Reference Types II, Vectors and Strings I Lecture
Handout DE ❘ EN
Lecture Examples
Referenzen (Clicker)
Summary 07
Exercise 6
Additional exercises: Floating Points
7 04.04 Vectors and Strings II, Recursion I Lecture
Handout DE ❘ EN
Lecture Examples
ShortestPath (Clicker)
Rekursion I (Clicker)
Summary 08
Exercise 7
Towers of Hanoi | ENG
8 11.04 Recursion II, Structs and Overloading Lecture
Handout DE ❘ EN
Code Examples
Rekursion III (Clicker)
nice BNF explanation (German) Summary 09
Exercise 8
9 18.04 Structs, Encapsulation and Classes Lecture
Handout DE ❘ EN
Code Examples
EBNF (Clicker)
Summary 10
Note: Q&A sessions on Thursday, April 18th. No exercises on Friday, April 19th.
Exercise 9
Binary Search Tree
02.05 Self-Assessment 3 (Kein neues Material) Self-Assessment III (Moodle)
10 09.05 Dynamic Data Types and Pointers Lecture
Handout DE ❘ EN
Code Examples
Additional Pointer Slides
Pointers I (Clicker)
Summary 11
Exercise 10
Binary Search Tree
11 16.05 Iterators and Containers Lecture
Handout DE ❘ EN
Code Examples
Recursive Structs (Clicker)
Summary 12
Exercise 11
12 23.05 Memory Management with Classes Lecture
Handout DE ❘ EN
Code Examples

Registration for the exercise session

Registration for the exercise sessions will open on Thursday, Feb 21st.

Time and place

The following exercise sessions are offered:

Time Place Assistant
Thu 13-15CHN D 48Piet De Vaere (EN)
Thu 17-19CHN D 48Moritz Schneider
Fri 08-10CAB G 56Joao Hector Rivera Verduzco (EN)
Thu 13-15CHN D 44Petr Novota
Thu 17-19CHN D 42Roland Schwan
Fri 13-15 Thu 13-15CAB G 56Martin Vahlensieck
Fri 15-17 Thu 13-15CHN D 42Vu Nguyen
Fri 08-10CHN D 42Pascal Schärli
Fri 13-15CHN D 42Yvan Bosshard
Fri 15-17 Thu 17-19CAB G 57Lukas Walker

Assistants marked with EN teach in English, all others in German.

Other assistants

Role Assistant Notes
Head TAMarco Ancona (EN)Main contact for administrative questions
BackofficeMarco Eilers-
BackofficeIvana Unkovic (EN)-

Old exam

The exam will take place on Monday, August 19th, 16:00-17:30 (exam duration: 90 minutes).
Here are some old exams for you to understand what to expect in terms of structure and length. Notice that the lecture content has slightly changed since previous years. The exams for Informatik I (D-ITET) and Informatik (D-MAVT) will be the same, so you can take both as reference.

Bonus exercises

There will be 3 bonus exercises during the semester (see the agenda above for the schedule). By solving these exercises you will get up to 0.25 grade points added on top of your exam grade. In order to access the bonus exercises you need to unlock them in Code Expert by solving assignments from previous weeks and earning sufficiently many experience points (XP).


The C++ tutorial that was also offered as part of the Vorkurs Informatik is still available, in case you want to refresh basic programming skills.

C++ Tutorial Öffnen

Hint: The tutorial is available in both German and English. You can switch the language any time.

Bjarne Stroustrup: Einführung in die Programmierung mit C++, Pearson Studium, 2010 | Also available online from the ETH Domain

Stephen Prata, C++ Primer Plus, Sixth Edition, Addison Wesley, 2012

Andrew Koenig and Barbara E. Moo: Accelerated C++, Addison-Wesley, 2000.


Prof. Dr. Bernd Gärtner and Dr. Michael Hoffmann kindly provided a script (lecture notes) that covers the material presented in the lecture.

Other useful resources