What are magic, or dunder, methods in Python? What are they for? Give a few examples.
~4 min by voice
How to approach it
They're checking whether the candidate understands that dunder methods are how you plug your class into Python's syntax and built-in functions (protocols), and whether they can give meaningful examples with nuances like __str__/__repr__ and __eq__/__hash__.
The interviewer will ask this question and listen. Think out loud and ask for a hint if you need one. When you're done, pause or tap “That's my answer”. In about a minute, your score and the points you covered show up here.