Re:The Norway Problem
by drno123 on Saturday April 03, 2021 @04:00AM
(#26679141)
Python vs JavaScript?
[ Parent
| on HN ]
Re:The Norway Problem
by speedgoose on Saturday April 03, 2021 @04:29AM
(#26679256)
Python vs PHP also.
> full of these sorts of interesting behavior
I don’t think that applies to Python - it’s quite strongly (although not statically) typed. I agree that it does apply to JavaScript and PHP.
I think this applies to Python pretty well. Although certainly not as bad as PHP, most JS traps also exist in Python (falsy values, optional glitchy semicolons, function scoped variables, mutable closure). There is many JS specific traps like this and also other Python specific ones (like static fields are also instance fields, Python versions and library dependency hell). However I find it easier to avoid them in JS than in Python with TypeScript, avoiding classes, ...