Advanced Python in German: 97 Flashcards on Decorators, Descriptors and Exceptions
German edition of Flip It's advanced Python deck: decorators, lambdas, exceptions, dunders and MRO, with German verbs to drill and 6 cards to fix before an interview.

Studying. But it's also a video game. 🎮
Flashcards, quizzes and games that make you actually remember.
Posted by
Related reading
Learn Python OOP in German: 59 Flashcards on Klassen, Vererbung and Magische Methoden
Study Python OOP with German explanations: 59 real flashcards on Klassen, Vererbung, MRO, Kapselung and dunder methods, plus 4 cards to fix and überschreiben vs überladen.
Master Python OOP in Spanish: 59 Flashcards on Clases, Herencia and Métodos Mágicos
Learn Python object-oriented programming with Spanish explanations: 59 real flashcards on clases, herencia, MRO, métodos mágicos and the Spanish terms to know.
Learn Python OOP in French: 59 Flashcards on Classes, Héritage and Méthodes Magiques
Study Python object-oriented programming in French with deck EO1367: 59 flashcards on classes, self, super(), MRO, dunder methods, @property and metaclasses.
Interviewing for a Python role in Berlin, Vienna or Zurich? JH1082 – Python: Fortgeschritten (Decorators, Lambda & Exceptions) is the German edition of Flip It's advanced Python deck. It has 97 cards with English fronts and German explanations. The English original is reviewed in Master Advanced Python. This article covers what the German version adds and which cards to fix first.
Study this deck: Python: Fortgeschritten (Decorators, Lambda & Exceptions)
1 / 10Metaclass in Python
Tap the card for the answer · swipe right if you knew it, left if not
Karten aus dem Deck
| Front | Back |
|---|---|
__new__ | __new__ erzeugt die Instanz (gibt sie zurück), __init__ initialisiert sie (gibt None zurück) |
__getattr__ vs __getattribute__ | __getattr__ nur, wenn das Attribut NICHT gefunden wird; __getattribute__ bei JEDEM Zugriff |
__setattr__ | self.x = y darin führt zu unendlicher Rekursion → object.__setattr__(self, 'x', y) |
| Can you stack multiple decorators? | Ja, sie werden von unten nach oben angewendet |
| Limitations of lambda expressions | Nur ein einzelner Ausdruck, keine Typannotationen, keine Schleifen |
except: vs except Exception: | Nacktes except: fängt auch SystemExit und KeyboardInterrupt ab |
| EAFP | Lieber um Vergebung bitten als um Erlaubnis fragen: versuchen, Exception abfangen |
| ExceptionGroup (Python 3.11+) | Mehrere gleichzeitig ausgelöste Exceptions, abgefangen mit except* |
Topics covered
Metaklassen and __prepare__, __init_subclass__, __class_getitem__, Descriptors (data vs non-data, lookup order), MRO and C3-Linearisierung, the diamond problem, kooperative Mehrfachvererbung, __slots__, __str__/__repr__, rich comparisons and functools.total_ordering, __hash__, reflected operators (__radd__), the container protocol (__getitem__, __contains__, __missing__), iterators, weakref, async protocols (__await__, __aenter__, __aiter__), decorators with arguments, functools.wraps, lru_cache, class-based decorators, lambdas with map/filter/sorted, closures, the walrus operator, try/except/else/finally, the BaseException hierarchy, custom exceptions, raise … from, assert and -O, EAFP vs LBYL, contextlib.suppress, @contextmanager, traceback.
Tipps für die deutsche Ausgabe
Read the title backwards. Cards 1-49 cover the object model: dunders, descriptors and MRO. Decorators begin at card 50, lambdas at 56 and exceptions at 60. Start with 50-97 if decorators and exceptions are what your interview will test.
Learn the German verbs, keep the English nouns. The deck uses the anglicisms German teams really say (Exception, Context Manager, Garbage Collector) but puts the verbs in German. Make reverse cards for auslösen (raise), abfangen (catch), erneut auslösen (re-raise) and unterdrücken (suppress, card 88). That way you can explain your own code in German, not just recognise it.
Fix these cards:
- Fronts 74, 87 and 91 are sentence-cased: write
functools.wraps,sys.exc_info()andfunctools.lru_cache. Python names are case-sensitive. - Card 5: the descriptor returns
value, which is never defined. Store it inobj.__dict__inside__set__. - Card 37: once
__setattr__raises, step 2 needsobject.__setattr__inside__new__. Otherwise your own constructor fails. - Card 63: if
open()fails,f.close()raisesNameError. Usewith open(...). - Card 87: since 3.11,
sys.exception()is simpler. Card 40'sOrderedDicthas been unnecessary since 3.6.
The Spanish edition of the same deck is covered too.
Find JH1082 – Python: Fortgeschritten (Decorators, Lambda & Exceptions) in the library on Flip It.
Ready to learn faster? 🚀
Join FLIP IT for free and turn studying into a game.