3 ms·
In general I recommend people stay away from static typing for a first language. I'm a static typing booster, but for beginners it is unnecessarily confusing.
by recursivecaveat 1y ago
In general I recommend people stay away from static typing for a first language. I'm a static typing booster, but for beginners it is unnecessarily confusing.
Compiler errors are by nature often counterfactual: "compiler couldn't prove that this wasn't none" or "once you pass through this generic method it's no longer known that your list of Animal only contains members of Dog" is usually more confusing and less tractable than a concrete test case that craps out your program. Then you can start poking away with prints at the stacktrace.
If you step through every single line of your execution carefully and inspect all the data, you're virtually certain to unstick yourself. I can't say the same if you get some gobbledygook from the compiler.