Values & References2 / 18
Up next

Arrays share a reference

const a = [1, 2, 3];
const b = a;
b.push(4);
// both names see the mutation
console.log(a);
What you're solving

two names, one array