₦airaland Forum

Welcome, Guest: RegisterLoginWith GoogleTrendingRecentNew

Stats: 3,330,384 members, 8,445,236 topics. Date: Tuesday, 14 July 2026 at 04:36 PM

Toggle theme

Loop Keep Running Non Stop, Past Counter..? - Programming - Nairaland

Nairaland ForumScience/TechnologyProgrammingLoop Keep Running Non Stop, Past Counter..? (380 Views)

1 Reply (Go Down)

Loop Keep Running Non Stop, Past Counter..? by Edipet(op): 9:36pm On Aug 05, 2023
I wrote down one line one of for loop code, when I logged into the console, it keep going, past counter, it was even going to infinity., I comment out the code but it was still running. I had to force off the laptop. Now all my html file are gone.
What could be the problem.? This is the second time this has happen to me?
Re: Loop Keep Running Non Stop, Past Counter..? by lordm(m): 9:43pm On Aug 05, 2023
Edipet:
I wrote down one line one of for loop code, when I logged into the console, it keep going, past counter, it was even going to infinity., I comment out the code but it was still running. I had to force off the laptop. Now all my html file are gone.
What could be the problem.? This is the second time this has happen to me?
check you conditions
Re: Loop Keep Running Non Stop, Past Counter..? by SUPREMOTM: 2:07am On Aug 06, 2023
Edipet:
I wrote down one line one of for loop code, when I logged into the console, it keep going, past counter, it was even going to infinity., I comment out the code but it was still running. I had to force off the laptop. Now all my html file are gone.
What could be the problem.? This is the second time this has happen to me?
Paste your code here, let's check it.
Re: Loop Keep Running Non Stop, Past Counter..? by peanutbutterr: 4:57am On Aug 06, 2023
you didn’t add the “break” keyword after your condition. that’s why you have an infinite loop running.
Re: Loop Keep Running Non Stop, Past Counter..? by ManAdii: 7:08am On Aug 06, 2023
Why did you force shutdown the system when you should have killed the process?
Re: Loop Keep Running Non Stop, Past Counter..? by Edipet(op): 8:34am On Aug 06, 2023
lordm:
check you conditions
thanks. The increment counter variable was wrong. Wrote "i = i++ instead of i = i + 1 or i++
Re: Loop Keep Running Non Stop, Past Counter..? by Edipet(op): 8:34am On Aug 06, 2023
peanutbutterr:
you didn’t add the “break” keyword after your condition. that’s why you have an infinite loop running.
thanks. The increment counter variable was wrong. Wrote "i = i++ instead of i = i + 1 or i++
Re: Loop Keep Running Non Stop, Past Counter..? by Edipet(op): 8:35am On Aug 06, 2023
SUPREMOTM:
Paste your code here, let's check it.
corrected thanks
Re: Loop Keep Running Non Stop, Past Counter..? by Edipet(op): 8:37am On Aug 06, 2023
ManAdii:
Why did you force shutdown the system when you should have killed the process?
correct. But i think it has caused problem to my VS code
1 Reply

For Loop And While Loop AlxHow Can I Loop This Data In VuejsDid You Really Code 5hours+ Non Stop While Learning To Code?234

Cheapest Vtu API In NigeriaLines Of CodeNigerian Job Employers