Why static Function is used in C++?
Answers were Sorted based on User's Feedback
Answer / sujai cn
Static functions are used to perform the tasks which are
independent of the state of object or to perform class wide
functions ex. to count the number of instaces (objects) are
there in existence.
| Is This Answer Correct ? | 14 Yes | 1 No |
Answer / rafiuddin
static functions can be called with out the class object
also. we can call static functions with scope resulation
operator.
| Is This Answer Correct ? | 9 Yes | 1 No |
Answer / mugdha taru
Because it is the only function which is accessible even
when class is not instantiateed
| Is This Answer Correct ? | 6 Yes | 3 No |
Answer / mugdha taru
Because it is the only function which is accessible even
when class is not instantiateed
| Is This Answer Correct ? | 2 Yes | 2 No |
How can we use the preprocessor #if and #elseif.
What is polymorphism and its types?
What is difference between #define and const?
Write an operator overloading program to write S3+=S2.
3. Differentiate verification and validation.
Tell me the scenario,Where we can use interfaces or Abstract class.And What is the difference between interfaces and abstract class?
What do we mean by a hidden argument in a function?
difference between structure and union.
what is data hiding.
What is the purpose of enum?
What is conditional Compilation?
How is polymorphism achieved?