Basic JavaScript - Compound Assignment With Augmented Addition

Tell us what’s happening:
Describe your issue in detail here.

Your code so far

let a = 3;
let b = 17;
let c = 12;

// Only change code below this line
var a =  3;
var b = 17;
var c = 12;
 
 a += 15
 b +=  9
 c += 7

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36

Challenge: Basic JavaScript - Compound Assignment With Augmented Addition

Link to the challenge:

You’ve done too much here. I would restart the lesson to get the original JS back. The only thing you want to do is change the three lines below the comment. Do not add any new lines of JS. And you definitely do not want to redeclare the variables again.

Look at the instructions again. They are telling you that

myVar = myVar + 5;

is the same thing as

myVar += 5;

So you just want to convert each of the three lines from the first format to the second.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.