Preparation for my bachelors thesis, a.k.a. learning erlang