0
How can I use assignment operators in Javascript? I'm really confused
Assignment operators
4 Answers
+ 1
Martin Taylor there were some that were like this
+= -= *=
What are these?
+ 1
These are a equivalent to
a = a + b
a = a - b
a = a * b
Example:
var a = 2;
var b = 4;
a += b //6
a = a + b //6