Introduction

Your take

Describe in one or two words what you think this course is about

(Post-it will be provided by the professor)

About the course

Goal: how to use a language to communicate with and instruct an information-processing agent

Computer Science notions: algorithms, data structures, and algorithmic techniques

Language for communication: Python (yes, it is a programming language)

Rumors

Some whispers of despair:

algorithms, computations, programming, etc., are something which I cannot handle – indeed, I did not like mathematics at the high school

I am not able to abstract a situation by using formal tools since I am not a formal person

I cannot learn a programming language

These are just prejudices

Yes, we can

Several of the things the book introduces are something that all of us already learned and digested during our life - it is only a matter of identifying them again to reuse them consciously

Intelligence is a muscle, it can be developed - we can learn anything, including Computer Science topics, despite what others say
More info in: Dweck, C. (2006). Mindset: The New Psychology of Success. Random USA. ISBN: 978-0345472328

A programming language is a language, such as Italian and English - we need time and practice to learn it properly

Suggested mindset: be an hacker
one who enjoys the intellectual challenge of creatively overcoming or circumventing limitations

We don't trust you!

OK, then see what it (has) happened

Bachelor:
History

Bachelor:
Humanities

Bachelor:
Information Science for Management

Did it happen?

Did some of you have experienced any of the following issues in the past? - Raise your hands if you were obliged:

  • to buy one or more books

  • to attend mandatorily a large part of the course for attending the final exam

  • not to participate to an exam session for some informal rule imposed by the professor

  • not to receive the maximum score if you attended the exam without attending the lectures

Books and material

Think and Compute: a Primer for Digital Humanists (official book of the course) + accompanying book How To Code in Python

All the material (including slides) is available in the GitHub repository of the course at https://github.com/comp-data/2025-2026/

Have you found a mistake in the official book? Please add a GitHub issue in the book repository

Communications

We use a Discord discussion group for communicating with each other

Invitation link to join the workspace: https://discord.gg/VGWGhwmN

Once you entered in the workspace following the previous link, you will be added to the private channel dedicated to the course (comp-data-25-26) by me

Please, do a Discord account as soon as possible (e.g. during the break) since I will close the invitation link in at the end of this week - and we will start to use it since Friday

Social channels

This course and the DHDK Master Degree are part BolDH, of an ecosystem conceived as a combination of education, research practices, and scholarly projects in the Digital Humanities domain (in Bologna)

It has its own website and an Instagram account (boldh.unibo)

These channels will be used to highlight interesting events and initiatives about the DH domain

Interacting

We will use the GitHub repository of the course for a series of activities, such as exercises and raising issues

Thus, please, create a new account on GitHub: https://github.com/join

Once logged into GitHub, go to the issue page of the course repository, and then feel free to add and respond to issues there

A very introductory guide to GitHub can be find online

Course organisation

As you know, Computational Management of Data is a 12 ECTS course, organised in two parts

  • Part I (October-December, 6 ECTS): dedicated to explore the basics of computational thinking and programming - taught by Silvio Peroni (me!)

  • Part II (February-March, 6 ECTS): dedicated to deep in topics related to data management and databases - taught by Ivan Heibi

Rules

Let's see the rules of this course

  • Two free text books are provided, and additional material can be found on the GitHub repository of the course

  • If you cannot attend, do not attend (even if attendance is recommended: you can ask questions)

  • At least six exam sessions per academic year

Part I: organisation

Theoretical part (30 hours), where I will introduce all the notions related to the course - no computer needed: 15 lectures of two hours each (today included)

Practical sessions, where Arcangelo Massari will be available for helping you in the issues that may arise during the course (e.g. solving exercises) - use Discord for coordination (e.g. topic to address and when)

Laboratorial part (12 hours), where Arcangelo (again) will have some practical lectures on programming languages - computer needed here

Theory, practice, laboratory

Theory: it introduces the tools for doing something - e.g. vocabulary and syntax of a language

Practice: it addresses assignments to enable people to learn and understand the correct way to use such tools - e.g. using the language vocabulary and syntax to write sentences to express a particular idea or situation

Laboratory: a workshop run by someone that enables one to use the tools learned to understand advanced concepts and to build wonderful (and complex) artifacts - e.g. writing a novel

Part I: calendar

October November December
13/10/25 09:00-11:00Introduction to the course 10/11/25 09:00-11:00Organising information: ordered structures 1/12/25 09:00-11:00Dynamic programming algorithms
15/10/25 09:00-11:00Introduction to Computational Thinking 14/11/25 09:00-11:00Laboratory 3/12/25 09:00-11:00Organising information: trees
16/10/25 12:00-14:00Algorithms 17/11/25 09:00-11:00Brute-force algorithms 5/12/25 09:00-11:00Laboratory
20/10/25 09:00-11:00Computability 19/11/25 09:00-11:00Organising information: unordered structures 10/12/25 09:00-11:00Backtracking algorithms
22/10/25 09:00-11:00Programming languages 21/11/25 09:00-11:00Laboratory 12/12/25 09:00-11:00Laboratory
24/10/25 12:00-14:00Laboratory 24/11/25 09:00-11:00Recursion 15/12/25 09:00-11:00Organising information: graphs
26/11/25 09:00-11:00Divide and conquer algorithms 17/12/25 09:00-11:00Greedy algorithms
28/11/25 09:00-11:00Laboratory 18/12/25 13:00-16:00Workshop

Exam

The exam consists of:

  1. A non-mandatory workshop (the day after the last lecture of Part I, i.e. 18 December 2025, 13:00-16:00), where the students are asked to organise themself in groups of 3-4 people (max. score: 3)

  2. A written examination (duration: one hour and an half) about the Part I content (max. score: 32)

  3. The implementation of a group project about the Part II content, where students are mandatorily asked to organise themself in groups of 3-4 people (max. score: 32)

Final score

If both the scores for points (2) and (3) are sufficient (i.e. min. 18), the final score is the sum of the scores of the previous slide, i.e. (1) + (2) + (3), divided by 2, and approximating it to the closest higher integer value in case of a decimal number

Any final score greater than 30 will be registered as 30 cum laude

Evaluation of the course

Usually, during one of the last lectures of the course, you will be asked to fill-up a questionnaire on the organisation of the course and related stuff - it is anonymous, of course

Please, do it carefully and honestly, since it is one of the most important inputs I will have to understand what can be improved in the next year course

The fact that the course of this year is slightly different from the one held during the previous year one is mainly due to the comments I have received through these questionnaires

About learning a new language

Do you think that attending only to all the classes of a 6 credit course (i.e. 30 hours) on a foreign language is enough to master its basics?

Learning a programming language is like learning a new language: you need to practice it (a lot) to master it properly

Final recommendations (1)

Umberto Eco (1980). The Name of the Rose. Available online

In the face of some inexplicable facts you must try to imagine many general laws, whose connection with your facts escapes you. Then suddenly [...] you perceive a line of reasoning that seems more convincing than the others. You try applying it to all similar cases [...] and you discover that your intuition was right.

There is no single solution to a given problem, and the best one can be found only trying (and making mistakes, and trying again and again) more than one approach

Final recommendations (2)

Stephen Toulmin (1958). The Uses of Arguments. Available online

The purpose of these studies is to raise problems, not to solve them

Please do ask questions

There are no stupid questions

My answers can be odd though, sometime

Thus, in order to avoid such odd answers, I could ask you to be patient and wait for the next lecture, so as to provide you with the best possible answer ever

Now a break, and then...

About thinking

Think and Compute

Understanding how your thinking mechanisms work and training you in been flexible and reactive while thinking can be achieved only by thinking about something

Thus, let us do a couple of experiments!

Experiment 1

Material:

  • 3 glasses

  • 4 knives

  • 1 book

Setting:

  • the glasses as vertexes of a triangle of equal sides

  • the base of each glass is separated from the other by the lenght of a knife

Goal of experiment 1

Using the knives, creating a platform on top of the glasses

The knives used must not touch the ground

The platform must support the weight of the book

What we learned from experiment 1

Approaching the solution may be difficult if there is no pattern provided by experience

It is important to analyse the situation to see if all the material available is useful, leaving out everything does not really help

Trial-and-error prodedure may be effective

Experiment 2

Material:

  • 4 glasses

  • 4 knives

  • 1 book

Setting:

  • the glasses at a corner of a square

  • the base of each glass is separated from the other by the lenght of a knife

Goal of experiment 2

Using the knives, creating a platform on top of the glasses

The knives used must not touch the ground

The platform must support the weight of the book

What we learned from experiment 2

Recognising essential similarity of a problem to one already solved makes the problem easier to solve

Experience is much more valuable if some general principle is derived from it

Use of patterns provided by experience is the most rapid way of solving problems

The general principle

Can you devise a general principle that can be use to solve both the situations introduced in the previous experiment?

Closing

These kinds of thinking exercises you performed today will characterise the entire course

Concepts such as abstraction, trial-and-error learning, prior experience, deriving general principles, practice, are key factors when learning a new language (including a new programming language)

Note: the two thinking experiments with glasses and knives introduced in this opening lecture come from the book The 5-Day Course in Thinking by Edward de Bono.

END Introduction