Explicitly defining variable data types vs. using the keyword 'var'? [closed]
https://softwareengineering.stackexchange.com/questions/42863
-
30-10-2019 - |
题
In C#, am I encouraged to use the all-purpose var keyword for every variable declaration? If yes, do I have to mention those special characters for literal values within the variable declaration like the M for decimal in the following statement:
var myDecimal = 14.5M;
If it makes a difference, I'm trying to do some web development with C#.
没有正确的解决方案