Skip to content

Instantly share code, notes, and snippets.

@raghuvarmabh
Created December 3, 2019 00:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save raghuvarmabh/ef5de9581fbafe534103c81fa735e99e to your computer and use it in GitHub Desktop.
Save raghuvarmabh/ef5de9581fbafe534103c81fa735e99e to your computer and use it in GitHub Desktop.
public static void main(String[] args) {
Person person = new Person("Tom Criuse", 44);
modifyPerson(person);
System.out.println(person.getName());
}
private static void modifyPerson(Person person) {
person.setName("Brad Pit");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment