Inscrivez-vous ou connectez-vous pour rejoindre votre communauté professionnelle.
Pass by Value: The method parameter values are copied to another variable and then the copied object is passed, that’s why it’s called pass by value.
Pass by Reference: An alias or reference to the actual parameter is passed to the method, that’s why it’s called pass by reference.
the pass by value only uses the contents of the variable, against the passage by reference it is the same variable it. any changes affect the variable
pass-by-reference; parameter will be the same as the callers passed argument.
pass-by-value; parameter will be copy of the caller passed argument.