Suppose I have this in C++:
void test(int &i, int &j) { ++i; ++j; }
The values are altered inside the function and then use
Java passes parameters by value, and has no mechanism to allow pass-by-reference.