Loading ...

type casting in c# | CodeAsp.Net

Posted in: ASP.NET Topics  »  Getting Started / General ASP.NET

type casting in c#

Subscribe to RSS
  • naval198409

    I have some confusion about the type casting in c#

    scince  as i know that c# highly typed cast .

    but in .net 2008 we define the variable  with the help of keyword var

    so how the compiler know about it what kind of variable is going to define and what is the background concept here 

    will you please tell me.


    Naval Kishor Pandey
  • irokhes


    "Local variables can be given an inferred "type" of var instead of an explicit type. The var keyword instructs the compiler to infer the type of the variable from the expression on the right side of the initialization statement. The inferred type may be a built-in type, an anonymous type, a user-defined type, or a type defined in the .NET Framework class library."


    good luck

  • Page 1 of 1 (2 items)