I want to define within a class a variable that can be read by any other function but that can be modified only by member function. For example, C# has the Property for this purpose. Traditionally, we've defined a function that returns a private member variable. But i think that does not look sophisticated.
Is there any other way to do this in C++?