+ 2
C# in Var keyword is it only use for int ?
3 Respuestas
+ 2
var it's basically a not define variable, so it can be int, string, bool, etc. The type chosen by the compiler and it's mostly used, when it's not sure that what kind of variable will be the var variable (especially important to know the difference between stack and heap and the value type, reference type)
+ 2
no its use for all