Dynamic “Weak” Typed Language
A dynamic language conducts type checking at runtime, in contrast to a static language, which validates at compile time. For PowerShell, if it encounters an invalid type operation during execution, it will throw a RuntimeException
. This design choice gives PowerShell flexibility and ease of use as a command-line shell and scripting language. In a static language, this behavior would result in a compiler error based on the analysis of the known types. Since types must be known, this often results in verbose declarations within the language.