S
stub
In a book the author said:"If you have a member function that accesses only
the static data members of a class, you can declare the function static as
well."
I don't understand that what's the advantages of making a member static
since static member functions can access non-static data in a class no
matter what.
Could someone explain on this? Thanks!
the static data members of a class, you can declare the function static as
well."
I don't understand that what's the advantages of making a member static
since static member functions can access non-static data in a class no
matter what.
Could someone explain on this? Thanks!