Computer Science - Object Oriented Programming Using C++ - Discussion

24. 

When an argument is passed by reference,

[A]. a variable is created in the function to hold the argument's value
[B]. the function cannot access the argument's value
[C]. a temporary variable is created in the calling program to hold the argument's value
[D]. the function accesses the argument's original value in the calling program
[E]. None of the above

Answer: Option D

Explanation:

No answer description available for this question.

Sundar said: (Mar 8, 2012)  
When an argument is passed by REFERENCE- Option D.

When an argument is passed by VALUE - Option A.

Ravi said: (Nov 18, 2013)  
Can any one explain why option 'B' is wrong?

Vaibhav said: (Mar 29, 2017)  
Reference is an alias to the original variable. It refers to the same memory Location.

Post your comments here:

Name *:

Email   : (optional)

» Your comments will be displayed only after manual approval.