Explain "passing by value", "passing by pointer" and
"passing by reference" ?
Answer Posted / roshanpr
During pass by value a duplicate copy of the parameters
passed are created. Any changes made to copy will not
reflect the actual parameters.
In pass by pointer(it called as pass by address) duplicate
copy is not created. and any chagnes made to copy will
reflect in actual parameters also.
| Is This Answer Correct ? | 10 Yes | 1 No |
Post New Answer View All Answers
When there is a global variable and local variable with the same name, how will you access the global variable?
How can we access protected and private members of a class?
Write about the local class and mention its use?
What is c++ course?
What is nested class in c++?
What is the syntax for a for loop?
What is c++ mutable?
What is virtual methods?
Do you know what are pure virtual functions?
What is switch case in c++ syntax?
Should the this pointer can be used in the constructor?
Why can’t you call invariants() as the first line of your constructor?
Difference between delete and free.
What are disadvantages of pointers?
What is c++ & why it is used?