PHP <-> FreeBASIC | Loop with condition at the end
PHP Used keywords: do while
do while
Description
do statement while (condition);
Input
- statement - statements
- condition - Logical value The condition can be any expression
Examples
PHP
Even one example in what situations we can use the operation loop with condition at the end:$i=10;
do --$i; while ( $i > 0);
do {
$i++;
if ($i==5)
break;
} while ( $i <10);
.
FreeBASIC Used keywords: do while loop
do loop while
Description
do
statements
loop while condition
Input
- statements - statements
- condition - Logical value The condition can be any expression
Examples
FreeBASIC
Even one example in what situations we can use the operation loop with condition at the end:i=10
do
i=i-1
loop while i > 0
do
i=i+1
if i=5 then
exit do
end if
loop while i <10
Loop with condition at the end in another programming language:
Differences to: