Answer Posted / shadab alam
static costructor of a class invoked automatically when
class is loded provided Main method is given.There is no
need to create instance of a class.
we can prove it by following program in c#
using System;
class aa
{
static aa()
{
Console.Write("without instance");
}
public static void Main()
{
}
}
output will be
---------------
without instance
| Is This Answer Correct ? | 13 Yes | 0 No |
Post New Answer View All Answers
Why we use get and set method in c#?
Is there regular expression (regex) support available to c# developers?
Is c# pass by reference?
Explain the advantage of using system.text.stringbuilder over system.string?
Is php better than c#?
What is Fragmentation and its Types?
What is difference between for and foreach loop in c#?
What does question mark mean in c#?
Define encapsulation?
Do events have return type c#?
Can you inherit multiple classes in c#?
What is meant by enumerable in c#?
What is a event in c#?
Explain the process of Serialization?
Why would you use a class property in c#?