Is it better in C++ to pass by value or pass by constant reference?

Is it better in C++ to pass by value or pass by constant reference?

I am wondering which is better practice. I realize that pass by constant reference should provide for better performance in the program because you are not making a copy of the variable.

11 Answers
11

Leave a Comment