Call by constant reference isn't really a different argument passing method.
It is just call by reference
It combines the const qualifier with the parameter type declaration and has the usual meaning.
A parameter that is declared to have values passed by constant reference
- do get initialized at the call
- are passed by reference (so the parameter is an alias for the argument)
- but the function is not allowed to assign to or otherwise change the parameter's value.
Syntax Example
Call by constant reference:
int findMax(const int& a, const int& b, const int& c);
We could instead declare findMax to use call by value:
int findMax(int a, int b, int c);
What is the difference between call by value and call by constant reference?