Not even close.
Faizaan
22

Hi Faizan, thanks for pointed it out.

But, correct me if I’m not wrong. In your example in this statement:

var1 = {a: 2}

In this case variable reference is changing, which is quite different from the result of the other statement:

var1.a = 2

Which is just a change in a property of var1, not the variable iftself.

Does make sense?

Show your support

Clapping shows how much you appreciated Henrique Luz Pereira’s story.