C++ Call By Reference

Call by reference method copies the address of an argument into the formal parameter. Inside the method, the address is used to access the actual argument used in the call. It means the changes made to the parameter affect the passed argument.

Output