A class is a collection of members which can be categorized int two types.
Members of a class which do require object of the class for initialization and Execution were know as Instance members.
Static Members :
Members of the class which don't require object of the class for initialization and Execution were known as Static members.
Example:
int x=100; // instance
static int y=200; // static
static void Main()
{
int z =300; // static
}
- Instance Members
- Static Members
Members of a class which do require object of the class for initialization and Execution were know as Instance members.
Static Members :
Members of the class which don't require object of the class for initialization and Execution were known as Static members.
Example:
int x=100; // instance
static int y=200; // static
static void Main()
{
int z =300; // static
}
No comments:
Post a Comment