3 ms·
What happens is people realized that python is not reliable enough for serious business applications and they to fix that. After experiencing static typing wit
by hasenj 10y ago
What happens is people realized that python is not reliable enough for serious business applications and they to fix that.
After experiencing static typing with TypeScript I don't really want to go back to dynamic typing.
- crdoconnor 10y ago>After experiencing static typing with TypeScript I don't really want to go back to dynamic typing. Javascript's main failing wasn't a lack of static typing it was a lack of type safety (which statically typed C also suffers from). Python didn't suffer from this. If you tried to convert an invalid string to an integer it won't just try and have a bad guess at what it thought that you meant (C, Perl and JS's default behavior), it would raise an exception instead.
- hasenj 10y agoNo the problem is when you have a method that takes three parameters you want know what these parameters are and what you can do with them. Trying to figure this out in a dynamically typed language is not fun. In TypeScript (with a decent editor, like VSCode) you just hover the parameter and you can immediately see what it is.
- crdoconnor 10y ago>Trying to figure this out in a dynamically typed language is not fun. Sure it is. Fire up the IPython REPL at the point in the code where you're intending to use it and experiment. Not only can you see what it takes, you can see what it does in real time and you can experiment on the results. >In TypeScript (with a decent editor, like VSCode) you just hover the parameter and you can immediately see what it is. Well, you can see that it's a string of some kind.
- vram22 10y ago>C, Perl and JS's default behavior That is the default behavior of Perl?
- crdoconnor 10y agoSee answer 2: https://stackoverflow.com/questions/288900/how-can-i-convert-a-string-to-a-number-in-perl https://stackoverflow.com/questions/288900/how-can-i-convert...
- vram22 10y agoThanks.