i'm currently in practice with c++, i found a situation(not critical).
as i read from tutorial & article, it said that good thing in passing argument by reference, but not to change the value inside the function, is to use the constant-references as the function parameter.
in situation that i just want to pass the argument to a function just for resource only, not to change the value itself,
1. so when is the right time to use the by-value parameter ?
2. when is the time not to use the constant-references parameter ?
may anyone have suggestion..
mic_kMember Since 24 Oct 2012
Offline Last Active Dec 19 2012 06:47 PM