++
operator.
i++;
is the equivalent of
i = i + 1;
Notei++;
, eliminating the need for the equal sign.
++
operator on myVar
.
HintmyVar
should equal 88
.
testString: assert(myVar === 88);
- text: You should not use the assignment operator.
testString: assert(/var\s*myVar\s*=\s*87;\s*\/*.*\s*([+]{2}\s*myVar|myVar\s*[+]{2});/.test(code));
- text: You should use the ++
operator.
testString: assert(/[+]{2}\s*myVar|myVar\s*[+]{2}/.test(code));
- text: You should not change code above the specified comment.
testString: assert(/var myVar = 87;/.test(code));
```