I was preparing a webinar on typing (for the Python Mastery Guild) and I was thinking about duck typing and how to explain it. I had come to the realisation – which is kind of obvious in hindsight – that dunder methods are for duck typing. It's through dunder methods that you add the duck-like behaviours that matter to your own classes. Not surprisingly, Trey's article on duck typing presents the same conclusion in a later section of the article.