Difference between revisions of "Talk:while"

From Bohemia Interactive Community
Jump to navigation Jump to search
(Forever ?)
 
(Forever ?)
Line 4: Line 4:
  
 
Meaning in the example below forever is really only 13hrs. 10000*5/60*60.
 
Meaning in the example below forever is really only 13hrs. 10000*5/60*60.
 
+
<code><nowiki>
 
_forever=true;
 
_forever=true;
 
 
while {( forever)} do {
 
while {( forever)} do {
  
// do something
+
    // do something
 
     sleep 5;
 
     sleep 5;
 +
 
};
 
};
 
+
</nowiki></code>
 
[[User:BarmyArmy|BarmyArmy]]BarmyArmy
 
[[User:BarmyArmy|BarmyArmy]]BarmyArmy

Revision as of 18:40, 2 May 2007

Forever ?

There is a BIS set limit on how many-time a while loop will run, I believe it is 10,000 times.

Meaning in the example below forever is really only 13hrs. 10000*5/60*60. _forever=true; while {( forever)} do { // do something sleep 5; }; BarmyArmyBarmyArmy