What is the use of static functions?

Answer Posted / amit

Amit Srivastava:
What i think , static functions are used with the conditions
where there is no need to occupy RAM memory unnecessarily.
As ,other than Static functions are attached with the object
and ready to use memory space as and when a object of that
class is instantiated.But Static functions are having only
one address as they are independent of Objects.

Is This Answer Correct ?    4 Yes 7 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Write about the role of c++ in the tradeoff of safety vs. Usability?

786


What is enum class in c++?

914


What do you mean by “this” pointer?

788


What is scope in c++ with example?

820


Explain all the C++ concepts using examples.

898






Perform addition, multiplication, subtraction of 2-D array using Operator Overloading.

3545


Is std :: string immutable?

750


What is dev c++ used for?

769


Name the debugging methods that are used to solve problems?

748


Explain about Virtual Function in C++?

763


Write a program which uses functions like strcmp(), strcpy()? etc

824


what are the decision making statements in C++? Explain if statement with an example?

849


Is it possible to have a recursive inline function in c++?

750


Which function should be used to free the memory allocated by calloc()?

767


How to declare a pointer to an array of integers?

817