7.3 — Passing arguments by reference | Learn C++
Second, when passing arguments by value, the only way to return a value back to the caller is via the function’s return value. While this is often suitable, there are cases where it would be more clear and efficient to have the function modify the argument passed in. Pass by reference solves both of these issues.
DA: 37 PA: 12 MOZ Rank: 61