C – Pass by Reference

Home/C - Tutorial/C - Functions/C – Pass by Reference
C – Pass by Reference 2017-06-12T12:01:05+00:00

Pass by Reference

When passing by reference technique is used, the address of the data item is passed to the called function. Using & operator we can determine the address of the data item. Note that function once receives a data item by reference, it acts on data item and the changes made to the data item also reflects on the calling function. Here you don’t need to return anything to calling function.

Example :

Output :

Enter two numbers



Sum of 10 and 20 is 30


Prev Next