[Solved] Explain the questions mentioned in the comments [duplicate]
Java passes a reference to an object in a method. You can call it a pointer if you want. Let’s say you have the object myBar in the class foo and you pass it to the change it method. It doesn’t pass the object itself it passes a reference to that object (a pointer if … Read more