Copying Reference Type Value in Js
// Copying Value:
let a = 10;
let b = a; // 10
b = b + b; // 20
// Expected behaviour!!
// Now, What's the behaviour of this:
let x = [1, 2, 3, 4];
let y = x;
y.pop(); // [1, 2, 3]
// Simple but what's in x - [1, 2, 3]
// How? Let's know how?
Fir...
mansidass.hashnode.dev3 min read