SHARE
TWEET

qbasic solve

a guest Jun 22nd, 2019 81 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. READ n$, m1, m2, m3
  2. WHILE n$ <> "end"
  3.     m4 = (m1 + m2 + m3) / 3
  4.     t1 = t1 + m1
  5.     t2 = t2 + m2
  6.     t3 = t3 + m3
  7.     IF m4 <= 50 THEN
  8.         S$ = "fail"
  9.     ELSE IF m4 < 70 THEN
  10.             S$ = "pass"
  11.         ELSE
  12.             S$ = "credit"
  13.         END IF
  14.     END IF
  15.     PRINT n$, m4, S$
  16.     READ n$, m1, m2, m3
  17. WEND
  18. PRINT "math", "bang", "eng"
  19. PRINT t1, t2, t3
  20. END
  21.  
  22.  
  23. DATA "nader",60,40,47
  24. DATA "amirah",70,60,50
  25. DATA "aseal",80,73,60
  26. DATA "end",-1,-1,-1
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top