Free Pascal <-> FreeBASIC | Elöltesztelő ciklus

Free Pascal

while do

Leírás

while condition do statement;
Használt kulcsszavak: do while

Bemenet

Megjegyzés: Itt használható utasítások:
Megszakító utasítás Következő iteráció elindítása

Példaprogramok

Free Pascal

Elöltesztelő ciklus lehetséges használata:
i:=0;
while i<10 do inc(i);
x :=0;
while i<20 do
begin
 i:= i+2;
 if i=16 then
 begin
    continue
 end;
 inc(x); 
end;
.
FreeBASIC

do while loop

Leírás

do while condition
statements
loop
Használt kulcsszavak: do while loop

Bemenet

Megjegyzés: Itt használható utasítások:
Megszakító utasítás Következő iteráció elindítása

Példaprogramok

FreeBASIC

Elöltesztelő ciklus lehetséges használata:
i=0
do while i<10
 i=i+1
loop
x =0
do while i<20
 i= i+2
 if i=16 then
    continue while
 end if
 x=x+1 
loop
Free Pascal

while do

Leírás

while condition do statement;
Használt kulcsszavak: do while

Bemenet

Megjegyzés: Itt használható utasítások:
Megszakító utasítás Következő iteráció elindítása

Példaprogramok

Free Pascal

Elöltesztelő ciklus lehetséges használata:
i:=0;
while i<10 do inc(i);
x :=0;
while i<20 do
begin
 i:= i+2;
 if i=16 then
 begin
    continue
 end;
 inc(x); 
end;
.
FreeBASIC

while wend

Leírás

while condition
statements
 wend
Használt kulcsszavak: while wend

Bemenet

Megjegyzés: Itt használható utasítások:
Megszakító utasítás Következő iteráció elindítása

Példaprogramok

FreeBASIC

Elöltesztelő ciklus lehetséges használata:
i=0
do while i<10
 i=i+1
loop
x =0
do while i<20
 i= i+2
 if i=16 then
    continue while
 end if
 x=x+1 
loop
Más nyelveken: en hu cz sk