Skip to main content

All Questions

Tagged with
-5 votes
2 answers
229 views

Term for refactoring looping logic for an event loop

Constrained by a main loop outside of my control (eg: UI event loop, game loop, etc...), I have a slow (relative to the main loop's expectations) algorithm involving a loop. Thus, I have to ...
Peter K's user avatar
0 votes
1 answer
147 views

Recursion, iteration, and ...? [closed]

Here are three common code structures that apply a function multiple times: foo(x) { if basecase(x) return k else return foo(g(x)) } uses recursion. for i in 0..10 { n *= bar(i) } uses ...
Alex Celeste's user avatar
0 votes
2 answers
268 views

Is there a special name for a condition which will break a loop if it increments a set number of times

Is there a name for including a limitation in a loop structure to prevent it from running if its primary condition becomes unwieldy. For example for (var i = 0; i < len; i++){ some_function();...
1252748's user avatar
  • 133
6 votes
6 answers
1k views

What does the English word "for" exactly mean in "for" loops?

English is not my first language, but since the keywords in programming languages are English words, I usually find it easy to read source code as English sentences: if (x > 10) f(); => "If ...
kol's user avatar
  • 422
3 votes
5 answers
266 views

Term for Performance Issues Due to Looping [closed]

Is there a term for performance issues caused by someone creates a loop that performs hundreds or thousands of actions that could have been done in bulk? My example is that I keep running into loops ...
Scott Keck-Warren's user avatar