Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
@billgates understandable if it's only for the primitive types. For things like generic collections and so on, var is much nicer.
I got into the habit of using var whenever possible though. -
donuts236785y@MrCSharp ah yes generics with multiple types similar to Java HashMap<> just less typing.
Was thinking dynamic vars is the only other reason in C# -
@Gregozor2121 it is not. when variables are names properly, and the structure of the code is sound and reasonable, then the type of the variable becomes obvious. And if you are going through some code to fix a bug then you really don;t need to know every type of every declared variable.
-
@Gregozor2121 I'd argue that if the code is clear enough, you can tell what type the variable is.
var is not an evil keyword in C# when variables and methods are named properly. -
Just use it like the typed language it is. It takes half a second to type the type.
-
@MrCSharp I just prefer using strong typing. That post was a semi meme too. There is nothing wrong with var, dynamic ect but people should use them if they dont have too. Limit the amount of programing features that you use and you wont have to constantly look into the docs when readings somebodies code. Follow KISS
Too lazy to come up with a better name...
Yea... the app still works...
5th time editing the crawler logic... 2 years now?
random