Advertisement
Guest User

Untitled

a guest
Sep 27th, 2017
122
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
QBasic 0.21 KB | None | 0 0
  1. CLS
  2. DIM a(10), max AS INTEGER
  3.  
  4. FOR i = 1 TO 10
  5.         a(i) = INT(RND * 100 - 10)
  6.         PRINT a(i)
  7.  
  8.         IF i = 1 OR max < a(i) THEN
  9.                 max = a(i)
  10.         END IF
  11. NEXT i
  12.  
  13. PRINT "MAX: ", max
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement