3 ms·
... of which type? Map<String,Object>? Then you have to use casts to convert Object to Integer for example. If static typing would be good enough, you would no
by qznc 14y ago
... of which type? Map<String,Object>? Then you have to use casts to convert Object to Integer for example.
If static typing would be good enough, you would not need casts. A cast basically says: "Hey compiler forget about type checking, just believe me that this thing has that type."
- tedunangst 14y agoDynamic typing basically says "Hey compiler forget about type checking, just believe me that this thing has that type."
- qznc 14y agoA dynamically typed language can still be strongly typed. For example, Python will give you an exception on a type error, where C/C++ could wreck havoc in your memory.
- tedunangst 14y agoUse dynamic_cast. Or java. Or c#.