3. ...And the good.. Im having trouble with this code, I even tried it in my repl.it and its not working, could anyone helo me figure out what I did wrong


#1


var counter = 1;
while (counter <= 20) {
if (counter % 3 == 0) {
console.log("Fizz");
counter++;
} else if(counter % 5 == 0){
console.log("Buzz");
counter++;
} else if(counter % 3 == 0 && counter % 5 == 0) {
console.log("FizzBuzz");
counter++;
} else {
console.log(counter);
counter++;`
}
};

https://www.codecademy.com/en/courses/spencer-sandbox/0/3?curriculum_id=506324b3a7dffd00020bf661


Replace this line with your code.


#2

else {
console.log(counter);
counter++;`
}

what is the character after counter++;?


#3

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