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


Please Help Members By Posting Answers For Below Questions

program explaining feautures of c++

1912


What is searching?

642


What is c++ iterator?

631


Explain function overloading

579


What are friend functions in C++?

614






What is the main purpose of c++?

535


What is the outcome of cout< a) 16 b) 17 c) 16.5

620


Is there any function that can skip certain number of characters present in the input stream?

577


What is the difference between while and do while loop?

550


Is there a c++ certification?

595


What does scope resolution operator do?

590


Define a pointer to a data member of the type pointer to pointer?

567


What is the difference between prefix and postfix versions of operator++()?

587


In a function declaration what does extern means?

589


How can you quickly find the number of elements stored in a static array?

627