so one use the var keyword in c# for implicit type declaration; what is the java equivalent?
noooooooooooo, grrrr, gonna crack open the java creator :P
Arturo
2010-08-09 20:25:16
To be fair, the only reason C# has `var` is because it is possible to instantiate types that have no name. There do not exist such types in Java.
Mike Caron
2010-08-09 20:26:27
And to be fair also; 1. it's only recent in C#, so Arturo can't be blaming "creators" and 2. it's only due to some other features that weren't in the 1.0 of either language that its become an idea that is useful rather than a great way to make code less clear and more bug-prone. It's needed in C#3.0, and would have a few useful cases in C#2.0, but would have been a bad thing in C#1.0.
Jon Hanna
2010-08-09 22:13:17