I'm starting to study OOP now and it's kind of weird to me. But I would like to know if I pass some parameter in a get
method, can it result in some error?
Ex:
class MostraNum
{
private:
int x;
public:
int getRetornaNum(int x)
{
return x;
}
};
int main()
{
MostraNum result;
cout<<result.getRetornaNum(100)<<endl;
return 0;
}