Question library
Questions from real interviews. Drill any of them by voice in a couple of minutes, with an interviewer, a score and feedback.
Why does Python need type annotations if it's a dynamic language? Are they checked when the program runs?JuniorYour project just added mypy, and you need to type a function that accepts any object with a read method. Would you describe that type with a Protocol or with an abstract base class, and how do they differ?Mid-levelWhen do you choose typing.Protocol and when an abstract base class? And how do you generally organize typing and mypy in a large project?Senior