Problems with freecodecamp

Maybe someone else also has the same problem?
I try to enter to my task in FCC but it stucks… I clear my browser, but it didn’t help.
Someone has any idea what it could be?

1 Like

Is this happening on one particular challenge or on multiple? How’s your internet connection?

I had any problems with internet connection and I can’t enter to another challenge, because when I’m entering I always get stuck…

I try to solve the “Confirm the ending” challenge (https://www.freecodecamp.org/challenges/confirm-the-ending), and when I put this code everything crashed… Maybe I made an infinite loop, but I know that in FCC there are some blockers for this case…
If it’s possible, please, help me but without spoilers!
Here is my code:

function confirmEnding(str, target)
{
for (var i = 0; i < str.length; i++)
if (target == str.substr(i))
{
return true;
} return false;
}

confirmEnding (“Open sesame”, “open”);

Without spoilers maybe tricky, but I’ll start with some hints.

  • Check your curly brackets for the for loop

  • You have some weird formatting applied to your strings. “ should be "

  • Think about using an else block or replace the if block with a ternary

That will at least allow it to run. Then you are on your own :slight_smile:

I’ll try, but now I can’t enter this challenge… :grinning:
How can I cancel my code?

ah, got you. Try go to freecodecamp and click on map, select your challenge from the list.

Try disabling auto run.
Another option is to clear the challenge data from your browser cache. This will cause you to lose any code you have written so far.

Thanks a lot!
I put #?run=disabled in my URL and it works! :grinning:

Awesome! Thanks for confirming this worked!