Just for example
Class A{
public:
int a;
};
int main(){
A test;
int b = test.a;
int c = test.a();
}
My question is that when accessing the member variable of a class, is there any difference between using test.a
and test.a()
?