Skip to content

Instantly share code, notes, and snippets.

@aotarola
Last active August 29, 2015 14:08
Show Gist options
  • Save aotarola/f426a022c34b5d2ef2ce to your computer and use it in GitHub Desktop.
Save aotarola/f426a022c34b5d2ef2ce to your computer and use it in GitHub Desktop.
js
function variablePass(x, obj1, obj2)
{
x /= 5;
obj1.id = "newId";
obj2 = {id: "newId"};
}
var x = 10;
var obj1 = {id: "oldId"};
var obj2 = {id: "oldId"};
variablePass(x, obj1, obj2);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment