How to break for loop in mikroc

Status
Not open for further replies.

polona1010

Member level 1
Joined
Apr 17, 2013
Messages
40
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,524
How to break for loop in mikroc

continue or break?

I cant find break in mikro c help

I need example
 

Sir can I use continue to?

What is return in for loop?
 

'Continue' is used to skip the remaining statements and the next iteration is done.
Eg:
PHP:
    for(;;){
    ------------
statement block 1;
if(condition to satisfied)
         continue;
----------------------
statement block 2
}
Here 'statement block 2' is skipped when continue instruction is executed, but the loop does not terminate.

---Use of return instruction
Suppose if you have a function as below
PHP:
void MyFunction(){
-------------
statement block1;
for(;;){
if(condition)
  return;
-----
statement block2;
}
------
statement block3
}

When return instruction is executed the function stops execution and reruns to the main program(or from where the function is called).
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…