while.bmx 268 B

12345678910111213
  1. Rem
  2. While executes the following section of code repeatedly while a given condition is true.
  3. End Rem
  4. Graphics 640,480
  5. While Not KeyHit(KEY_ESCAPE) 'loop until escape key is pressed
  6. Cls
  7. For i=1 to 200
  8. DrawLine rnd(640),rnd(480),rnd(640),rnd(480)
  9. Next
  10. Flip
  11. Wend