คำสั่งควบคุมลำดับการทำงาน do...while
รูปแบบ
do
{
    คำสั่ง 1;
    คำสั่ง 2;
     ...;
}
while (เงื่อนไข);
ตัวอย่าง Flowchart การทำงาน
ตัวอย่าง source code จาก flowchart
#include  <stdio.h>
#include  <conio.h>
#include  <graphics.h>
void main()
{
     clrscr();
     int i=0;
     int gdriver = DETECT, gmode, errorcode;
     initgraph(&gdriver, &gmode, "c:/tc/bgi/");
     do
     {
         circle(200,i,50);
         i=i+50;
     }
     while (i<200);
     getch();
     closegraph();
}
กลับหน้าหลัก |