title: Java is always pass by value so why am I getting reference when using Array.get(index)?
body: <p>I was working on this bug in my application and saw something very weird:</p>
  
  <pre class="lang-java prettyprint-override"><code>    selectedService = dataResponse.getServices().get(position);
      selectedService.setPrice(3000);
      dataResponse.getServices().get(position).getPrice(); // Returns 3000 which should be 0
  </code></pre>
  
  <p>Shouldn't the get method copy the object into <code>selectedService</code>? If not how to copy it?</p>