Hey guys just another is this the right way to do it question.
I like to make sure im doing it right even if it seems to work :)
Thanks as Always :)Code:#include <iostream>
class loser
{
public:
int loserPower;
};
void modifyingLoser(loser *mLoser);
int main()
{
loser me;
loser *ptrMe;
ptrMe=&me;
modifyingLoser(ptrMe);
std::cout<<ptrMe->loserPower;
getchar();
return 0;
}
void modifyingLoser(loser *mLoser)
{
mLoser->loserPower=10;
}