Skip to content
Sharp

Type Hints · interview question

Which option describes the most likely pitfall around optional and collections?

Multiple choiceEasychapter-10-curatedpremiumtype-hintsoptional-and-collections
Choose one answer
Answer and explanation

Correct answer

C. If None and collection contents are left implicit, edge cases spread across many call sites.

Why

If None and collection contents are left implicit, edge cases spread across many call sites. Calling out that risk matters because strong candidates mention that dynamic languages still benefit from explicit expectations.

Test yourself on Type Hints

A free test with instant, explained results. No account needed.

Start free test
All Type Hints questions →