Basic JavaScript lessons bug

Basic JavaScript lessons bug
0

#1

Hi

I just went through the Basic JavaScript curriculum.

2 lessons hang every time I submit the answer

Iterate with JavaScript While Loops
and
Iterate Odd Numbers With a For Loop

Can someone help to feedback to FCC?


#2

Hmmm… Both work for me.

Are you using Chrome browser?

Are you receiving the checkmark confirmation on those two when you run the tests?

Can you post the code you submitted?


#3

Yep, I’m using Chrome.
The pages hang after I click the ‘Run the Tests’ button.
Can’t even scroll to see the checkmark info below


#4

I would guess they are hanging because you forced an infinite loop.

What does the code you typed in look like?


#5

The first guess is that you may have created an infinite loop.

Since FCC automatically run your code on page load, your browser will always be unresponsive.
To prevent that you can set disable the autorun with a run=disable url parameter.

Here’s an example:

URL: http://www.freecodecamp.com/challenges/Algorithm-meet-Algorithm#?solution=function%20meetBonfire(argument)

No-Run URL: http://www.freecodecamp.com/challenges/Algorithm-meet-Algorithm#?run=disabled&solution=function%20meetBonfire(argument)

#6

That’s it! Thanks for the prompt replies! All of you!


#7

Sounds like you have created a situation where the test condition never becomes false.

Without seeing your code it would be hard to say how that happened. If you post your code someone will probably find your problem and lead you to a solution.