3 ms·
I think in C++... if you want to be sure the method/function does not alter the data globally and speed is not a concern, then pass by copy. If you want the met
by 0wned 17y ago
I think in C++... if you want to be sure the method/function does not alter the data globally and speed is not a concern, then pass by copy. If you want the method to alter the data globally, then pass by reference. If you want speed, but don't want alteration then pass by const reference.