Editor not working

Doing the c++ course but on the loops sections I enter code into the editor but it does not save, tried pressing the run button I get a message ‘Have you entered the while loop’ Yes but no matter what I do, seven attempts so far, Codeacademy does not recognise it. I have edited the file in the terminal and copied it to my local machine where it runs fine. How do I move on if I cannot get the ‘next’ button to become active ?


Hello @trevorpearson , can you include a link to the course? You can try signing off/on again to see if that helps.

Hello! Additionally to what cofeencake said, can you post your code, please? It could be possible that you’ve created an infinite loop?

Thank you for trying to help here is the text of the progam (which is correct) and a screenshot the while loop it wants me to enter is directly above the error messege saying it isn’t there, and in the terminal the program running correctly


int main() {

int guess;

int tries = 0;

std::cout << “I have a number 1-10.\n”;
std::cout << "Please guess it: ";
std::cin >> guess;

// Write a while loop here:
while ( guess !=8 && tries <50) {
std::cout << "Wrong, try again: ";
std::cin >> guess;

if (guess == 8) {

std::cout << "You got it!\n";



It’s probably just poor testing (text matching). If everything’s working as expected consider viewing the solution and replacing the line; for really harsh text matches even a single space could cause problems. If you could link the lesson someone might have the chance to try it just in case it’s something else.

Still no joy tried copying the solution and still the same error I think this is the link to the lesson
it is simple enough code

So far as I’m aware using Get Unstuck -> Replace with Solution would tick off this instruction so at least you could move forward; not an ideal solution but I wouldn’t waste your own time trying to work around the testing. Not sure what the issue is here (no idea whether I passed the testing on this one or just forced it) :person_shrugging:.