C# Programming - Constructors - Discussion

Discussion Forum : Constructors - General Questions (Q.No. 15)
15.
Which of the following statements are correct about static functions?
Static functions are invoked using objects of a class.
Static functions can access static data as well as instance data.
Static functions are outside the class scope.
Static functions are invoked using class.
Answer: Option
Explanation:
No answer description is available. Let's discuss.
Discussion:
2 comments Page 1 of 1.

Pranit said:   1 decade ago
Instance function are invoked by using object of class and Static functions are invoked using class.

NAVEEN KUMAR OBEROI said:   1 decade ago
Static variables/instances get the memory prior to the creation of objects so there is no need for the object to be created. Before creation of an object static variables gets initialized. In the same way static functions does not require to invoke through objects these gets invoked by using class name.

Post your comments here:

Your comments will be displayed after verification.