Hacker News new | ask | show | jobs
by laike9m 934 days ago
Your solution is fine. Pyright can infer the return types, so you don't need to annotate the return type.

In fact this is describe in the solution https://github.com/laike9m/Python-Type-Challenges/blob/main/...