Tuesday, 17 September 2013

Python, Java, C: Pass by Reference or Pass by Value Differences

Python, Java, C: Pass by Reference or Pass by Value Differences

I just read the following article on what passing by reference and passing
by value means: http://qntm.org/call
So just to make sure I'm understanding correctly... Does that mean that
calling by value in functions will NOT alter the original inputs, only a
local copy of that input? However, since in Java and Python, the values
are actually references to values, does that mean calling by value in
functions WILL alter the original inputs?

No comments:

Post a Comment