infinite-loop Questions

4

Solved

I am stuck with HAL_Delay() function. When i call this function HAL_Delay() , control stuck in infinite loop. While searching for the problem, I found this http://www.openstm32.org/forumthread2145...
Frieder asked 22/12, 2018 at 22:51

12

Writing an infinite loop is simple: while(true){ //add whatever break condition here } But this will trash the CPU performance. This execution thread will take as much as possible from CPU's po...
Exothermic asked 13/9, 2011 at 12:50

2

Solved

I am asking this question only for the sake of knowledge(because i think it has nothing to do with beginner like me). I read that C-programmers prefer for(; ;) {....} over while(1) {....} ...
Serbocroatian asked 30/6, 2013 at 20:44

4

I am experiencing a very tricky defect in my WPF application to track down. The error message is: An infinite loop appears to have resulted from repeatedly invalidating the TimeManager during t...
Dakar asked 5/2, 2013 at 19:37

4

Solved

Let's say I have this simple dummy component: const Component = () => { const [state, setState] = useState(1); setState(1); return <div>Component</div> } In this code, I updat...
Mccoy asked 11/10, 2022 at 20:54

5

Solved

I have a python function foo with a while True loop inside. For background: It is expected do stream info from the web, do some writing and run indefinitely. The asserts test if the writing was do...
Vile asked 9/4, 2020 at 13:34

3

Solved

In C++ loops such as for(;;) {} used to be undefined behavior prior to P2809R3. Trivial infinite loops are not Undefined Behavior, whereas they are not in C(?). In the aforementioned proposal, it ...

2

Solved

Is there a way to detect infinite HTTP 3xx redirect loops on the server? (Not necessarily the exact moment when the client gives an error, as the number of redirects required for that is client-dep...
Eau asked 13/3, 2012 at 11:22

3

Solved

I know what an Infinite Loop error is. Is a stack overflow error the same thing. If not, what is the difference? Can you give example code as well?
Diehl asked 30/11, 2014 at 21:58

5

Solved

I need to be able to continuously run my BackgroundWorker. The DoWork event contains a pool threaded process and the OnComplete updates my UI. I have not been able to find a way to infinitely loop...

7

Solved

I have to run a legacy Zope2 website and have some grievance with it. The biggest issue is that, occasionally, it just locks up, running at 100% CPU load and not answering to requests anymore. Whil...
Lotze asked 23/11, 2009 at 9:14

9

Solved

Updated, see below! I have heard and read that C++0x allows an compiler to print "Hello" for the following snippet #include <iostream> int main() { while(1) ; std::cout << "Hello...

7

How can I make a effect in swift similar to this: I want the animation to loop forever.
Subtangent asked 18/6, 2016 at 3:40

1

Solved

I am trying to implement Navigation using single activity and multiple Composable Screens. This is my NavHost: @Composable @ExperimentalFoundationApi fun MyNavHost( modifier: Modifier = Modifier, ...

11

Solved

I want to create an infinite loop that counts up and down from 0 to 100 to 0 (and so on) and only stops when some convergence criterion inside the loop is met, so basically something like this: fo...
Wenzel asked 5/9, 2018 at 14:13

15

Is it possible to get an infinite loop in for loop? My guess is that there can be an infinite for loop in Python. I'd like to know this for future references.
Habit asked 13/12, 2015 at 17:23

2

Solved

I am using curl and setting all the parameters correctly (as far as I know) but CURLOPT_TIMEOUT is being ignored and allowing for an infinite loop. Here is the configuration for my Curl Request: $...
Carswell asked 9/9, 2014 at 1:13

4

Solved

I keep getting an error, if without else. I tried else if as well for (;;) { System.out.println("---> Your choice: "); choice = input.nextInt(); if (choice==1) playGame(); if (cho...
Centner asked 18/12, 2013 at 23:42

9

If I write code creating an infinite loop, with my new Excel, the Ctrl + Break no longer works. Neither does the Esc key, etc. I've looked all over the web and it appears that Microsoft has a bug ...
Winstonwinstonn asked 12/2, 2014 at 19:32

1

Solved

I'm using Jetpack Compose + Navigation (Single Activity, no Fragments) and i'm trying to perform a navigation route as follow: SplashScreen ---(delay)---> AuthScreen ---(if successful)--&g...

6

Solved

This is node.js. I have a function that might become an infinite loop if several conditions are met. Untrusted users set these conditions so for the purpose of this question please assume the infi...
Laoighis asked 13/7, 2012 at 18:26

5

Solved

I am using laravel 5.6 and have the problem, when I use the command "php artisan vendor:publish" in the console, I get the following error: [ERROR] Use of undefined constant STDIN - assumed 'STDIN...
Spooner asked 10/4, 2018 at 6:6

6

Solved

I've got a script that runs an infinite loop and adds things to a database and does things that I can't just stop halfway through, so I can't just press Ctrl+C and stop it. I want to be able to som...
Gallager asked 3/10, 2015 at 13:3

5

Solved

Basically, I need to ensure that input is an integer, like so: do { printf("Enter > "); scanf("%d", &integer); } while (/* user entered a char instead of an int */); I have tried variou...
Ruminate asked 26/7, 2015 at 2:17

9

Solved

I have an example of nested array: var testArray = [1,2,[3,4,[5,6],7],8,9,[10,11],12]; Here is my function for getting nested array length: Array.prototype.getLength = function() { var sum = 0...

© 2022 - 2025 — McMap. All rights reserved.