3 ms·
In both (classic) Python and JavaScript, there is no static typing and you can change the type of existing objects, access all their fields, and add/remove meth
by devit 11y ago
In both (classic) Python and JavaScript, there is no static typing and you can change the type of existing objects, access all their fields, and add/remove methods and field any time.
The only languages with "weaker" typing are languages with no concept of types at all.
- qznc 11y agoI'd argue that C++ is weaker than Java, although both have the concept of types. If you cast from one class to another, C++ will do it without hesitation. Java will do a runtime check and throw a ClassCastException if it fails.
- kylebgorman 11y agoC++ has both checked casts and unsafe casts.
- legulere 11y agoStrong/weak typing generally refers to types being implicitly converted. It's a almost completely orthogonal concept from static/dynamic typing. For instance C has several implicit integer width conversions. Javascript, PHP and Ruby are often used as examples for weak typing.
- deleted 11y ago[deleted]
- deleted 11y ago[deleted]