9. Can you please explain the difference between pass by value and pass by reference?

In pass by value approach, the called function creates another copies of the variables passes as arguments. In this approach, the values of the original variables remain unchanged. However, we come across situations where we need to change the values of the original variables. Then the values may b passed by reference.

10. What are References in C++?

A restricted type of pointer in C++ is known as a reference. A reference can be assigned only once and can not have a null value.

Download Interview PDF