Like This Site? 
 
RSS Feed Follow Us 

on Twitter! Be Our Fan!

How to use do {} while(0);

Share this post!
 Vote this!

This is going to be a very brief tutorial, but hopefully it is still useful.

Let's start off with some structure:

1do
2{
3  // Insert code here.
4} while(0);

You should already be familiar with do { /*insert code*/ } while(/*condition*/); but if not, I'll give you a brief explanation. Basically, the code inside the body of the do statement will be executed as long as the condition of the while statement is true.  more...

0 comments:

Post a Comment