3 ms·
Very much disagree. Your argument seems like a static typing vs not and unless you're writing a small trivial thing, having types very quickly bear fruit. Also
by rockwotj 4y ago
Very much disagree. Your argument seems like a static typing vs not and unless you're writing a small trivial thing, having types very quickly bear fruit. Also most of the good code I read these days are data oriented programs (which is largely inspired by functional programming and see rules 5 here http://users.ece.utexas.edu/~adnan/pike.html http://users.ece.utexas.edu/~adnan/pike.html) and types are very important to get the transformations correct in these systems.
- satya71 4y agoBoth Python and JS have static typing. Edit: remove unnecessary snark
- rockwotj 4y agoStrong typing maybe? Depends on what you define these terms to be. For me. Static typing is a compiler that verifies your types are correct. Neither Python nor JavaScript has this. Python allows for type annotations, which is very different. It has no (builtin) enforcement. JavaScript has no type pins whatsoever, TypeScript does. There is a proposal to add types to JavaScript but that's not approved AFAIK
- satya71 4y agoRight, when I said JS with static typing, I meant TypeScript. Python has type checkers, see mypy and pyright, and I use them regularly. Most bugs that could be found by static type checker no longer make it into test or production for me.