18 lines
378 B
Plaintext
18 lines
378 B
Plaintext
'Another demo of DO loops
|
|
Dim As Integer Counter
|
|
Print "First loop DO..LOOP UNTIL"
|
|
Counter = 0
|
|
Do
|
|
Print Counter
|
|
Counter = Counter + 1
|
|
Loop Until Counter Mod 6 = 0
|
|
Print "Counter Mod 6 = "; Counter Mod 6
|
|
Print "First loop DO WHILE..LOOP"
|
|
Counter = 1
|
|
Do While Counter Mod 6 <> 0
|
|
Print Counter
|
|
Counter = Counter + 1
|
|
Loop
|
|
Print "Counter Mod 6 = "; Counter Mod 6
|
|
End
|