What is static function and static class?

Answer Posted / anthony michael

Static function and static variable does not below to single
instance of a class.

To access static functions we don't need instance of a class
instead it can be accessed using the class name followed by
::operator as:
[class_name::static_function() ]

Is This Answer Correct ?    8 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What happens when you make call 'delete this;'?

814


What is meant by entry controlled loop? What all C++ loops are exit controlled?

834


What are the rules for naming an identifier?

790


What are stacks?

826


What is an arraylist c++?

909


What is scope resolution operator in c++ with example?

789


What is an inclusion guard?

857


What is c++ prototype?

783


What is the fastest c++ compiler?

780


What are the c++ access specifiers?

1071


What are c++ manipulators?

813


What is the use of function pointer?

761


What is c++ similar to?

850


How do you define/declare constants in c++?

786


explain the reference variable in c++?

800