Python Birdies: Codegolfing for better understanding (and fun)

Codegolfing, the art of condensing ones code, seems counterproductive to good programming standards. In this talk, I will argue, with the use of examples, that this need not be the case, that playing with a language can give you better understanding of its internals, and in turn make you a better programmer.

Tags: Algorithms

Scheduled on thursday 15:25 in room lounge

Speaker

Jonathan Oberländer (L3viathan2142)

Jonathan started programming at the tender age of 12, after accidentally buying a book about C++. He quickly moved on to other languages (VBScript, AutoIt, PHP, Javascript, Perl, ...), but it wasn't until his Bachelor studies in Computational Linguistics (Saarland University) that he started learning Python, after having to choose between it and a Java course. Since then, he has mostly stayed true to Python, except for the occasional affair with esoteric programming languages. After finishing his Master's in Cognitive Science (Trento) and Computer Science (Prague), he started working as a full-time Python developer at the German price comparison website billiger.de

Description

Codegolfing means taking a programming task and trying to answer it with a byte-minimal correct solution. Such an answer often takes shortcuts, is horribly inefficient, and definitely violates almost 100% of PEP 8. Like any playful interaction with a subject, it can however improve your understanding of it, as well as teach you about weird interactions regarding operator precedence, lexer quirks and more.

After going over basic definitions, I will take a small number of well-known or straightforward programming tasks and go through the act of golfing an answer together step by step.