Computer Science, asked by yogestar007, 11 months ago

static member function program in c++​

Answers

Answered by Anonymous
5

Answer:

Just like static data member, static member function is also a class function; it is not associated with any class object. In above program X and Y are two static data members and print() is a static member function. According to the rule of static in C++, only static member function can access static data members.

Answered by puneetgoyal12
3

Answer:

Just like static data member, static member function is also a class function; it is not associated with any class object. In above program X and Y are two static data members and print() is a static member function. According to the rule of static in C++, only static member function can access static data members.

Similar questions