field initialization : Member Variable : Class C# Examples


C# Examples » Class » Member Variable »

 

field initialization









    
class  FieldInitExample
        {
                int  x  =  5;
                int  y;

                public  FieldInitExample()  :  this(5)
                {
                }

                public  FieldInitExample(int  y)
                {
                        this.y  =  y;
                }
        }
    
   
  
   




HTML code for linking to this page:

Follow Navioo On Twitter

C# Examples

 Navioo Class
» Member Variable