Hacker News new | ask | show | jobs
by IshKebab 261 days ago
> The extra typing clarification in python makes the code harder to read.

It depends what you mean by "read". If you literally mean you're doing a weird Python poetry night then sure they're sort of "extra stuff" that gets in the way of your reading of `fib`.

But most people think of "reading code" and reading and understanding code, and in that case they definitely make it easier.

2 comments

As someone who has read code as easily as English for decades (which is apparently rare, if my co-workers are any indication), too many type annotations clutter it up and make it a lot harder to read. And this is after having used Typescript a lot in the past year and liking that system - it works well because so much can be inferred.
Python also has type inference. I don't think it really has more type annotation "noise" than Typescript does.

    'Twas brillig: Adjective and the slithy toves: Noun
    Did gyre: Verb and gimble: Verb in the wabe: Noun