What is static function and static class?

Answer Posted / anthony michael

Sourisengupta

Static Class is not possible in C++. But it can be done in
Managed C++

Static Class:
For Static Class we can't create Instances and It can only
hold Static member's.

Creating a static class is therefore much the same as
creating a class that contains only static members and a
private constructor. A private constructor prevents the
class from being instantiated.

Is This Answer Correct ?    5 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Difference between overloaded functions and overridden functions

802


What is the best c++ book for beginners?

812


Write about the access privileges in c++ and also mention about its default access level?

812


How many types of classes are there in c++?

789


What is iomanip c++?

802


What is the latest version on c++?

863


Using a smart pointer can we iterate through a container?

800


Explain the difference between struct and class in terms of access modifier.

919


What is #include iomanip?

748


What is srand c++?

810


Explain function overloading and operator overloading.

811


How new/delete differs from malloc()/free?

839


What is the best c++ compiler for windows 10?

764


What are the two shift operators and what are their functions?

802


write a c++ program to create class student having datamember name,Roll_no,age,and branch intilcization all the member using constructor print the all the details on the screen.

2449