3 ms·
> a strong type system It's a myth that dynamic languages can't have strong types. Python aborts almost immediately whenever it can. For instance, adding a nu
by crazypython 6y ago
> a strong type system
It's a myth that dynamic languages can't have strong types. Python aborts almost immediately whenever it can. For instance, adding a number to a string? Exception. Accessing undefined properties?
Furthermore there's a language-standard static type checker, mypy.
> pattern matching
We have that in Python 3.10.
> immutability-by-default for lists and dictionaries
We do have tuples and frozendict.
Arguably its implementations of functional features are much weaker than "truly" functional ones such as Lisp, Haskell, OCaML or F#.
- deleted 6y ago[deleted]
- moron4hire 6y agoRuntime type checking is most definitely not what people mean when they talk about strong type systems.
- reikonomusha 6y agoStrong != static.
- ewi_ 6y agoI love python, and I don't know if the GP are good points, but your answer is really disengenuous. > > pattern matching > We have that in Python 3.10. > > immutability-by-default for lists and dictionaries > We do have tuples and frozendict. 3.10 like the version that is not released yet? Tuples an frozendicts, so precisely non default list and dicts?
- mypalmike 6y agoThe tools are there but you don't like their names.
- c-cube 6y agoNeither tuples nor frozen dicts offer efficient (logarithmic or constant time) updates, like lists or balanced trees or HAMT do. You can't really write a program with only immutable structures in python, unless you accept it will be unbearably slow, even for python. Clojure, erlang, elixir, these are dynamically typed and functional.
- Can_Not 6y ago> Python aborts almost immediately whenever it can doesn't sound very strong