4 ms·
Or Python, or JavaScript. The reverse is true, you can have static type-checking without OOP, like C, Rust, Haskell.
by remram 4y ago
Or Python, or JavaScript.
The reverse is true, you can have static type-checking without OOP, like C, Rust, Haskell.
- tsimionescu 4y agoI feel compelled to note that C only has the lightest possible amount of type checking, if even that. For example, the following program compiles: #include <stdio.h> void foo(double* c) { printf("%g", *c); } void bar() { printf("bar"); } int main() { int x = 9; int* y = &x; foo(x); //warning foo(y); //warning bar(1.0); //not even a warning }