I\'ve written the following JavaScript:
var myArray = [\'a\', \'b\', \'c\']; var copyOfMyArray = myArray; copyOfMyArray.splice(0, 1); alert(myArray); // aler
Everything is copied by reference except primitive data types (strings and numbers IIRC).